LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Compiling gcc-4.1.0 on a system with glibc-2.4 installed (https://www.linuxquestions.org/questions/linux-software-2/compiling-gcc-4-1-0-on-a-system-with-glibc-2-4-installed-434662/)

tomdkat 04-12-2006 09:50 PM

Compiling gcc-4.1.0 on a system with glibc-2.4 installed
 
So, I managed to get glibc-2.4 installed and everything works fine except for a compile error I've been getting when I build gcc-4.1.0.

Here is the error:

Code:

ranlib ./libgcov.a
./xgcc -B./ -B/usr/i686-pc-linux-gnu/bin/ -isystem /usr/i686-pc-linux-gnu/include -isystem /usr/i686-pc-linux-gnu/sys-include -L/home/tom/build/gccobj/gcc/../ld -O2  -O2 -g -O2  -DIN_GCC    -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition  -isystem ./include  -fPIC -g -DHAVE_GTHR_DEFAULT -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED  -I. -I. -I../../gcc-4.1.0/gcc -I../../gcc-4.1.0/gcc/. -I../../gcc-4.1.0/gcc/../include -I../../gcc-4.1.0/gcc/../libcpp/include  -fexceptions -fvisibility=hidden -DHIDE_EXPORTS -c ../../gcc-4.1.0/gcc/unwind-dw2.c -o libgcc/./unwind-dw2.o
./xgcc -B./ -B/usr/i686-pc-linux-gnu/bin/ -isystem /usr/i686-pc-linux-gnu/include -isystem /usr/i686-pc-linux-gnu/sys-include -L/home/tom/build/gccobj/gcc/../ld -O2  -O2 -g -O2  -DIN_GCC    -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition  -isystem ./include  -fPIC -g -DHAVE_GTHR_DEFAULT -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED  -I. -I. -I../../gcc-4.1.0/gcc -I../../gcc-4.1.0/gcc/. -I../../gcc-4.1.0/gcc/../include -I../../gcc-4.1.0/gcc/../libcpp/include  -fexceptions -fvisibility=hidden -DHIDE_EXPORTS -c ../../gcc-4.1.0/gcc/unwind-dw2-fde-glibc.c -o libgcc/./unwind-dw2-fde-glibc.o
In file included from ../../gcc-4.1.0/gcc/unwind-dw2-fde-glibc.c:62:
../../gcc-4.1.0/gcc/unwind-dw2-fde.c:53: warning: missing braces around initializer
../../gcc-4.1.0/gcc/unwind-dw2-fde.c:53: warning: (near initialization for 'object_mutex.__data')
../../gcc-4.1.0/gcc/unwind-dw2-fde.c:53: error: '__LOCK_INITIALIZER' undeclared here (not in a function)
../../gcc-4.1.0/gcc/unwind-dw2-fde.c:53: warning: missing initializer
../../gcc-4.1.0/gcc/unwind-dw2-fde.c:53: warning: (near initialization for 'object_mutex.__data.__nusers')
make[3]: *** [libgcc/./unwind-dw2-fde-glibc.o] Error 1
make[3]: Leaving directory `/home/tom/build/gccobj/gcc'
make[2]: *** [libgcc.a] Error 2
make[2]: Leaving directory `/home/tom/build/gccobj/gcc'
make[1]: *** [stage1_build] Error 2
make[1]: Leaving directory `/home/tom/build/gccobj/gcc'
make: *** [bootstrap-lean] Error 2

Has any else attempted building gcc-4.1.0 on a system with glibc-2.4 already installed? If so, have you had any success?

Peace...

foo_bar_foo 04-12-2006 10:14 PM

you did
--enable-threads=posix ?

tomdkat 04-12-2006 10:33 PM

Quote:

Originally Posted by foo_bar_foo
you did
--enable-threads=posix ?

Yep, at first. Then I re-ran configure without --enable-threads.

Peace...

tomdkat 04-13-2006 12:56 AM

Well, it looks like an issue with the current gcc-4.1.0 release. I'm building a gcc-4.1 snapshot dated 04072006 and I'm in the stage2 part of the build and all is well. :)

I'll update this thread as I discover more.

Peace...

tomdkat 04-13-2006 01:58 PM

Well, I got gcc-20060407 built against glibc-2.4. It reports itself as gcc 4.1.1, so I'm thinking the next maintenance release of gcc-4.1 will work fine.

I couldn't get the java frontend (GCJ) built, but the C and C++ frontends built fine.

Peace...

vas77 12-22-2006 07:27 PM

gcc 4.1.0 with glibc2.4
 
Can you post how you resolved this problem?

I've tried the newer gcc 4.1.1 with glibc2.5 and it has the same problem.

Thanks.

In file included from ../../gcc-4.1.0/gcc/unwind-dw2-fde-glibc.c:435:
../../gcc-4.1.0/gcc/unwind-dw2-fde.c:53: warning: missing braces around initializer
../../gcc-4.1.0/gcc/unwind-dw2-fde.c:53: warning: (near initialization for 'object_mutex.__data'
../../gcc-4.1.0/gcc/unwind-dw2-fde.c:53: error: '__LOCK_INITIALIZER' undeclared here (not in a f
../../gcc-4.1.0/gcc/unwind-dw2-fde.c:53: warning: missing initializer
../../gcc-4.1.0/gcc/unwind-dw2-fde.c:53: warning: (near initialization for 'object_mutex.__data. ')
make[2]: *** [libgcc/./unwind-dw2-fde-glibc.o] Error 1

us_ed 12-26-2006 03:33 AM

Hi all
I am install FC4,but not install gcc.
When i am look system,i found gcc-4.0.0
I will install gcc-4.1.1.
How i had reinstall gcc-4.1.1


All times are GMT -5. The time now is 11:04 AM.