undefined reference to `__EH_FRAME_BEGIN__' error using sh-coff,sh-hms gcc-3.1

Rekha Deshmukh RekhaD@kpit.com
Tue May 28 22:23:00 GMT 2002


Hi all!

I have successfully built the mingw toolchains for sh-coff and sh-hms targets.
The source code used was binutils-2.12.1, gcc-3.1, newlib-1.10.
When I compile any program using this toolchain it gives the following error. 

y:\mingwsh-coff3.1\bin\..\lib\gcc-lib\sh-coff\3.1\libgcc.a(__main.o): In function `__do_global_dtors':
libgcc2.c:1904: undefined reference to `__EH_FRAME_BEGIN__'
y:\mingwsh-coff3.1\bin\..\lib\gcc-lib\sh-coff\3.1\libgcc.a(__main.o): In function `__do_global_ctors':
libgcc2.c:1924: undefined reference to `__EH_FRAME_BEGIN__'

After going to the source of libgcc2.c I observed that the coff and hms target should not set the EH_FRAME_SECTION_NAME macro. That is why it is setting the __EH_FRAME_BEGIN__ variable. 
I am unable to troubleshoot beyond this.
Please let me know what may be the problem? Is it something in the build which is setting this. 

The build commands I followed for building the gcc were: 
../src/gcc-3.1/configure --enable-languages=c,c++ --with-newlib --target=sh-coff --prefix=/usr/gcc-3.1 
make LANGUAGES="c c++" all-gcc
make LANGUAGES="c c++" install-gcc

Thanks in advance
Regards
Rekha



More information about the Gcc-bugs mailing list