LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   problem in installing glibc 2.7 (https://www.linuxquestions.org/questions/linux-software-2/problem-in-installing-glibc-2-7-a-694234/)

tanmoy_tiger 01-01-2009 06:56 AM

problem in installing glibc 2.7
 
i am using opensuse 10.2.i want to install glibc-2.7 with add-ons port,libidn,nptl but during make i get following error:
glibc-2.7/compile/nptl -o /root/glibc-2.7/compile/libc.so -T /root/glibc-2.7/compile/shlib.lds /root/glibc-2.7/compile/csu/abi-note.o /root/glibc-2.7/compile/elf/soinit.os /root/glibc-2.7/compile/libc_pic.os /root/glibc-2.7/compile/elf/sofini.os /root/glibc-2.7/compile/elf/interp.os /root/glibc-2.7/compile/elf/ld.so -lgcc
/root/glibc-2.7/compile/libc_pic.os: In function `__libc_fork':
/root/glibc-2.7/posix/../nptl/sysdeps/unix/sysv/linux/i386/../fork.c:76: undefined reference to `__sync_bool_compare_and_swap_4'
/root/glibc-2.7/compile/libc_pic.os: In function `__nscd_drop_map_ref':
/root/glibc-2.7/nscd/nscd-client.h:320: undefined reference to `__sync_fetch_and_add_4'
/root/glibc-2.7/compile/libc_pic.os: In function `nscd_getpw_r':
/root/glibc-2.7/nscd/nscd_getpw_r.c:232: undefined reference to `__sync_fetch_and_add_4'
/root/glibc-2.7/compile/libc_pic.os: In function `__nscd_drop_map_ref':
/root/glibc-2.7/nscd/nscd-client.h:320: undefined reference to `__sync_fetch_and_add_4'
/root/glibc-2.7/compile/libc_pic.os: In function `nscd_getgr_r':
/root/glibc-2.7/nscd/nscd_getgr_r.c:321: undefined reference to `__sync_fetch_and_add_4'
/root/glibc-2.7/compile/libc_pic.os: In function `__nscd_drop_map_ref':
/root/glibc-2.7/nscd/nscd-client.h:320: undefined reference to `__sync_fetch_and_add_4'
/root/glibc-2.7/compile/libc_pic.os:/root/glibc-2.7/nscd/nscd_gethst_r.c:400: more undefined references to `__sync_fetch_and_add_4' follow
/root/glibc-2.7/compile/libc_pic.os: In function `__nscd_get_map_ref':
/root/glibc-2.7/nscd/nscd_helper.c:404: undefined reference to `__sync_val_compare_and_swap_4'
/root/glibc-2.7/compile/libc_pic.os: In function `*__GI___libc_freeres':
/root/glibc-2.7/malloc/set-freeres.c:39: undefined reference to `__sync_bool_compare_and_swap_4'
collect2: ld returned 1 exit status
make[1]: *** [/root/glibc-2.7/compile/libc.so] Error 1
make[1]: Leaving directory `/root/glibc-2.7'
make: *** [all] Error 2
linux-exhh:~/glibc-2.7/compile #

What should i do?mail me at tanmoy.justu@gmail.com

jiobo 01-02-2009 04:17 PM

Have you checked your build environment to see that you satisfy dependencies?

Garlictoast 04-20-2009 05:22 PM

Try this
 
Your problem is with building, not installing. There are other problems with actually installing that I don't know how to solve yet. But you may be able to get a good build by adding CFLAGS=" -march=i386 -O2" to your configure command---or whatever architecture you have in the -march= specification. I think this has been required since glibc version 2.6. Omitting the architecture produces errors like those you posted, though I don't know for sure if this will solve your build problem


Quote:

Originally Posted by tanmoy_tiger (Post 3393392)
i am using opensuse 10.2.i want to install glibc-2.7 with add-ons port,libidn,nptl but during make i get following error:
glibc-2.7/compile/nptl -o /root/glibc-2.7/compile/libc.so -T /root/glibc-2.7/compile/shlib.lds /root/glibc-2.7/compile/csu/abi-note.o /root/glibc-2.7/compile/elf/soinit.os /root/glibc-2.7/compile/libc_pic.os /root/glibc-2.7/compile/elf/sofini.os /root/glibc-2.7/compile/elf/interp.os /root/glibc-2.7/compile/elf/ld.so -lgcc
/root/glibc-2.7/compile/libc_pic.os: In function `__libc_fork':
/root/glibc-2.7/posix/../nptl/sysdeps/unix/sysv/linux/i386/../fork.c:76: undefined reference to `__sync_bool_compare_and_swap_4'
/root/glibc-2.7/compile/libc_pic.os: In function `__nscd_drop_map_ref':
/root/glibc-2.7/nscd/nscd-client.h:320: undefined reference to `__sync_fetch_and_add_4'
/root/glibc-2.7/compile/libc_pic.os: In function `nscd_getpw_r':
/root/glibc-2.7/nscd/nscd_getpw_r.c:232: undefined reference to `__sync_fetch_and_add_4'
/root/glibc-2.7/compile/libc_pic.os: In function `__nscd_drop_map_ref':
/root/glibc-2.7/nscd/nscd-client.h:320: undefined reference to `__sync_fetch_and_add_4'
/root/glibc-2.7/compile/libc_pic.os: In function `nscd_getgr_r':
/root/glibc-2.7/nscd/nscd_getgr_r.c:321: undefined reference to `__sync_fetch_and_add_4'
/root/glibc-2.7/compile/libc_pic.os: In function `__nscd_drop_map_ref':
/root/glibc-2.7/nscd/nscd-client.h:320: undefined reference to `__sync_fetch_and_add_4'
/root/glibc-2.7/compile/libc_pic.os:/root/glibc-2.7/nscd/nscd_gethst_r.c:400: more undefined references to `__sync_fetch_and_add_4' follow
/root/glibc-2.7/compile/libc_pic.os: In function `__nscd_get_map_ref':
/root/glibc-2.7/nscd/nscd_helper.c:404: undefined reference to `__sync_val_compare_and_swap_4'
/root/glibc-2.7/compile/libc_pic.os: In function `*__GI___libc_freeres':
/root/glibc-2.7/malloc/set-freeres.c:39: undefined reference to `__sync_bool_compare_and_swap_4'
collect2: ld returned 1 exit status
make[1]: *** [/root/glibc-2.7/compile/libc.so] Error 1
make[1]: Leaving directory `/root/glibc-2.7'
make: *** [all] Error 2
linux-exhh:~/glibc-2.7/compile #

What should i do?mail me at tanmoy.justu@gmail.com


dewilso4 08-03-2011 12:45 PM

Good call, Garlictoast. However, glibc2.7 or later won't build with -march=i386, but setting -march=i486 or higher will allow the build to proceed. For my environment, I did the following:
Code:

./configure -prefix=/usr CFLAGS="-march=i686 -O2"
followed, of course, by
Code:

make && make install


All times are GMT -5. The time now is 01:41 AM.