From 23ae9ca88799109e397a7eb88f06e4bae6f97ae2 Mon Sep 17 00:00:00 2001 From: Pedro Alves Date: Wed, 6 Jan 2010 22:28:21 -0500 Subject: [PATCH] Remove absolute path from libust.so I noticed that the libust.so ld script is installed to the same directory as libust.so.0 and libust-initializer.o, so removing the absolute paths from them allows linking with a libust.so that isn't in the sysroot or installed under /usr/, like e.g., in a DESTDIR directory. This was useful for testing a release with everything extracted some randome prefix, e.g., libust.so in $RANDOM_UNPACK_DIR/usr/lib, and pointing LD_LIBRARY_PATH to $RANDOM_UNPACK_DIR/usr/lib. --- Makefile.am | 2 +- libust.ldscript.in | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile.am b/Makefile.am index 9385116..3f23249 100644 --- a/Makefile.am +++ b/Makefile.am @@ -16,7 +16,7 @@ ldscripts_DATA = libust.so libust-initializer.o CLEANFILES = $(ldscripts_DATA) ./tests/libust-initializer.Po libust.so: libust.ldscript.in - $(SED) -e "s@\@FORMAT\@@$(LIBFORMAT)@" -e "s@\@PATH\@@${libdir}@g" < $< > $@ + $(SED) -e "s@\@FORMAT\@@$(LIBFORMAT)@" < $< > $@ # It is very important to compile the initializer with PIC otherwise we # may get obscure errors when linking to shared libraries. diff --git a/libust.ldscript.in b/libust.ldscript.in index 3babac6..d3f9fe8 100644 --- a/libust.ldscript.in +++ b/libust.ldscript.in @@ -1,4 +1,4 @@ /* GNU ld script Use the shared library, but the link with initializer too */ OUTPUT_FORMAT(@FORMAT@) -GROUP ( @PATH@/libust.so.0 @PATH@/libust-initializer.o ) +GROUP ( libust.so.0 libust-initializer.o ) -- 2.34.1