LD problem
krisztian.kocsis@optimaster.eu
krisztian.kocsis@optimaster.eu
Mon Jul 4 10:56:00 GMT 2011
More information about the Binutils mailing list
Mon Jul 4 10:56:00 GMT 2011
- Previous message (by thread): LD problem
- Next message (by thread): Should rename ELFOSABI_LINUX into ELFOSABI_GNU, and drop ELFOSABI_HURD
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Hello! In the meanwhile I'v discovered that ld (or gcc driver) turns on the --no-allow-shlib-undefined option. I haven't discovered the reason (I'v checked the patches, etc. - no success) but if I add the -Wl,--allow-shlib-undefined (ld's man page says that this is the default but it seems that the opposite is the default) it corrects the behavior. Thanks for the help! BR, Krisztian Kocsis On Mon, 4 Jul 2011 10:24:16 +0930, Alan Modra wrote: > On Sun, Jul 03, 2011 at 02:53:18PM +0200, Krisztian Kocsis wrote: >> Hello! >> >> I have a link dependency problem. If I try to link an application >> with >> an .so file (exc. -lssl) the linker wants to link all its dependency >> libraries not just libcrypto.so but libdl.so and libz.so also. >> >> The toolchain is a crosstool-ng toolchain consists of: >> - binutils-2.21 >> - gcc-4.5.3 >> - eglibc-2.14 >> >> If I add -Wl,--as-needed it does not help. There are still >> references in >> the NEEDED entry for these libraries. I'v checked but there are no >> referenced symbols from these libraries. > > I think it most likely you have missed some reference. Run ld under > gdb with a breakpoint on one of the following lines in elflink.c > add_needed = TRUE; > ret = elf_add_dt_needed_tag (abfd, info, soname, add_needed); > Examine "h". > >> Do somebody know how can I restore the normal workflow, is any >> configure option or something else? >> >> BR, >> Krisztian Kocsis
- Previous message (by thread): LD problem
- Next message (by thread): Should rename ELFOSABI_LINUX into ELFOSABI_GNU, and drop ELFOSABI_HURD
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Binutils mailing list