summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2008-12-04 06:09:56 +0000
committerUlrich Drepper <drepper@redhat.com>2008-12-04 06:09:56 +0000
commit593798821113c57fe10f1fdf6593658d99d05ca9 (patch)
treef1f7dbff9a01291553595e774717b1901c9f380f
parenta845f68bf43f90e0670ed6b33154f2aff98ad46b (diff)
downloadelfutils-593798821113c57fe10f1fdf6593658d99d05ca9.tar.gz
[USE_TLS] Link libasm.so with libpthread.
-rw-r--r--libasm/ChangeLog4
-rw-r--r--libasm/Makefile.am7
2 files changed, 10 insertions, 1 deletions
diff --git a/libasm/ChangeLog b/libasm/ChangeLog
index 2894970e..c98deb64 100644
--- a/libasm/ChangeLog
+++ b/libasm/ChangeLog
@@ -1,3 +1,7 @@
+2008-12-03 Ulrich Drepper <drepper@redhat.com>
+
+ * Makefile.am [USE_TLS]: Like libasm.so with libpthread.
+
2008-01-11 Ulrich Drepper <drepper@redhat.com>
* libasm.h (DisasmGetSymCB_t): Change type of fourth and fifth
diff --git a/libasm/Makefile.am b/libasm/Makefile.am
index bd5779e8..62b5ee29 100644
--- a/libasm/Makefile.am
+++ b/libasm/Makefile.am
@@ -65,12 +65,17 @@ if !MUDFLAP
libasm_pic_a_SOURCES =
am_libasm_pic_a_OBJECTS = $(libasm_a_SOURCES:.c=.os)
+libasm_so_LDLIBS =
+if USE_TLS
+libasm_so_LDLIBS += -lpthread
+endif
+
libasm_so_SOURCES =
libasm.so: libasm_pic.a libasm.map
$(LINK) -shared -o $@ -Wl,--whole-archive,$<,--no-whole-archive \
-Wl,--version-script,$(srcdir)/libasm.map,--no-undefined \
-Wl,--soname,$@.$(VERSION) \
- ../libebl/libebl.a ../libelf/libelf.so
+ ../libebl/libebl.a ../libelf/libelf.so $(libasm_so_LDLIBS)
if readelf -d $@ | fgrep -q TEXTREL; then exit 1; fi
ln -fs $@ $@.$(VERSION)