This is the mail archive of the
libc-alpha@sources.redhat.com
mailing list for the glibc project.
Re: messed up shlibs.lds
- From: Daniel Jacobowitz <drow at mvista dot com>
- To: Guido Guenther <agx at sigxcpu dot org>
- Cc: libc-alpha at sources dot redhat dot com
- Date: Fri, 24 Oct 2003 11:04:58 -0400
- Subject: Re: messed up shlibs.lds
- References: <20031024094910.GB1023@bogon.ms20.nix>
On Fri, Oct 24, 2003 at 11:49:10AM +0200, Guido Guenther wrote:
> Hi,
> since quite some time I'm getting a messed up shlibs.lds somtimes. It
> has ld error ouput mixed into it e.g.:
>
> [..snip..]
> /* DWARF 2 */
> .debug_info 0 : { *(.debug_info .gnu.linkonce.wi.*) }
> .debug_abbrev 0 : { *(.debug_abbrev) }
> .de/var/scratch/crossdev/toolchain/cross-mips64-linux/bin/../lib/gcc/mips64-linux/3.4/../../../../mips64-linux/bin/ld: cannot open crti.o: No such file or directory
> bug_line 0 : { *(.debug_line) }
> .debug_frame 0 : { *(.debug_frame) }
> [..snip..]
>
> I've seen this when cross building i386->mips64, ppc->mips64 as well as
> ppc->i386. Is anybody else seeing this?
> -- Guido
I've reported this a number of times. James just hit it on m68k, too.
I thought I'd posted my latest patch for this but I can't find it now
in the archives so I guess I didn't. Here it is:
2003-09-26 Daniel Jacobowitz <drow@mvista.com>
* Makerules (shlib.lds): Make sure that ld doesn't try to link
anything while generating the linker script.
--- glibc-2.3.2/Makerules.orig 2003-09-26 12:50:18.000000000 -0400
+++ glibc-2.3.2/Makerules 2003-09-26 12:50:46.000000000 -0400
@@ -479,6 +479,7 @@ ifeq (yes,$(elf))
# not for shared objects
$(common-objpfx)shlib.lds: $(common-objpfx)config.make $(..)Makerules
$(LINK.o) -shared -Wl,-O1 \
+ -nostdlib -nostartfiles \
$(sysdep-LDFLAGS) $(config-LDFLAGS) $(LDFLAGS.so) \
-Wl,--verbose 2>&1 | \
sed > $@T \
--
Daniel Jacobowitz
MontaVista Software Debian GNU/Linux Developer