summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2006-02-28 06:47:56 +0000
committerMike Frysinger <vapier@gentoo.org>2006-02-28 06:47:56 +0000
commit8439614d20241e02ca4457cc38a66589fe5aa813 (patch)
tree919441a169ac0aa4bc50f3f93f70af6003d5566d /test
parent7e5815897276af4764df7f5acf77142076f96088 (diff)
set dynamic linker if we are building as shared
Diffstat (limited to 'test')
-rw-r--r--test/Rules.mak7
1 files changed, 4 insertions, 3 deletions
diff --git a/test/Rules.mak b/test/Rules.mak
index 203e6a188..a52de4f0a 100644
--- a/test/Rules.mak
+++ b/test/Rules.mak
@@ -13,9 +13,7 @@ TESTDIR=$(top_builddir)test/
-include $(top_builddir).config
-ifndef UCLIBC_LDSO
-UCLIBC_LDSO := ld-uClibc.so.0
-endif
+UCLIBC_LDSO ?= $(firstword $(wildcard $(top_builddir)lib/ld*))
#--------------------------------------------------------
# Ensure consistent sort order, 'gcc -print-search-dirs' behavior, etc.
@@ -95,6 +93,9 @@ ifneq ($(strip $(HAVE_SHARED)),y)
HOST_LDFLAGS += -static
endif
LDFLAGS += -B$(top_builddir)lib -Wl,-rpath,$(top_builddir)lib -Wl,-rpath-link,$(top_builddir)lib
+ifeq ($(findstring -static,$(LDFLAGS)),)
+LDFLAGS += -Wl,--dynamic-linker,$(UCLIBC_LDSO)
+endif
# Filter output