2001-05-11 Roland McGrath <roland@frob.com>
authorRoland McGrath <roland@gnu.org>
Fri, 11 May 2001 08:09:48 +0000 (08:09 +0000)
committerRoland McGrath <roland@gnu.org>
Fri, 11 May 2001 08:09:48 +0000 (08:09 +0000)
* sysdeps/mach/hurd/Makefile ($(link-rpcuserlibs)): Don't use
$(build-module) here, since we don't need the full magilla.
Just use $(build-module-helper) and append our special options.

sysdeps/mach/hurd/Makefile

index 007016d..e8cd4dc 100644 (file)
@@ -149,12 +149,13 @@ lib-noranlib: $(common-objpfx)hurd/libhurduser-link.so
 endif
 
 $(link-rpcuserlibs): %-link.so: %_pic.a
-# The $(build-module) variable now contains a sequence of several commands,
-# so we can't tweak the ld command just by adding text to this command line.
-       $(build-module)
-LDFLAGS-link-rpcuserlibs = -nostdlib -Wl,-soname=$(*F).so$($(*F).so-version)
-LDFLAGS-libmachuser-link.so = $(LDFLAGS-link-rpcuserlibs)
-LDFLAGS-libhurduser-link.so = $(LDFLAGS-link-rpcuserlibs)
+# These shared objects are just for the purpose of linking libc,
+# so they don't need abi-note.o linked into them.
+       $(build-module-helper) \
+               -o $@ -nostdlib -Wl,-soname=$(*F).so$($(*F).so-version) \
+               -Wl,--whole-archive \
+               $(filter-out $(map-file) $(+preinit) $(+postinit),$^) \
+               $(no-whole-archive) $(LDLIBS-$(@F:lib%.so=%).so)
 
 # And get them into the libc.so ldscript.
 $(inst_libdir)/libc.so: $(rpcuserlibs)