else
$(objpfx)makedb: $(objpfx)libdb.a
endif
+
+# Depend on libc.so so a DT_NEEDED is generated in the shared objects.
+# This ensures they will load libc.so for needed symbols if loaded by
+# a statically-linked program that hasn't already loaded it.
+$(objpfx)libdb.so: $(common-objpfx)libc.so
-# Copyright (C) 1996 Free Software Foundation, Inc.
+# Copyright (C) 1996, 1997 Free Software Foundation, Inc.
# This file is part of the GNU C Library.
# The GNU C Library is free software; you can redistribute it and/or
libutil-routines:= login login_tty logout logwtmp pty
-
include ../Rules
+
+# Depend on libc.so so a DT_NEEDED is generated in the shared objects.
+# This ensures they will load libc.so for needed symbols if loaded by
+# a statically-linked program that hasn't already loaded it.
+$(objpfx)libutil.so: $(common-objpfx)libc.so
$(objpfx)libieee.a: $(objpfx)ieee-math.o
rm -f $@
ln $< $@
+
+# Depend on libc.so so a DT_NEEDED is generated in the shared objects.
+# This ensures they will load libc.so for needed symbols if loaded by
+# a statically-linked program that hasn't already loaded it.
+$(objpfx)libm.so: $(common-objpfx)libc.so
endef
object-suffixes-left = $(object-suffixes)
include $(patsubst %,$(..)o-iterator.mk,$(object-suffixes))
+
+# Depend on libc.so so a DT_NEEDED is generated in the shared objects.
+# This ensures they will load libc.so for needed symbols if loaded by
+# a statically-linked program that hasn't already loaded it.
+$(objpfx)libcrypt.so: $(common-objpfx)libc.so
# Depend on libc.so so a DT_NEEDED is generated in the shared objects.
# This ensures they will load libc.so for needed symbols if loaded by
# a statically-linked program that hasn't already loaded it.
-$(services:%=$(objpfx)libnss_%.so): $(common-objpfx)libc.so
+$(services:%=$(objpfx)libnss_%.so) $(objpfx)libnsl.so: $(common-objpfx)libc.so
ifeq ($(build-shared),yes)
$(objpfx)libresolv.so: $(common-objpfx)libc.so
# The DNS NSS modules needs the resolver.
-$(objpfx)libnss_dns.so: $(objpfx)libresolv.so
+$(objpfx)libnss_dns.so: $(objpfx)libresolv.so $(common-objpfx)libc.so