Revert "Build: Add an rpath of $(LIBDIR) to binary targets."
authorMichael Adam <obnox@samba.org>
Thu, 6 Mar 2008 16:49:07 +0000 (17:49 +0100)
committerMichael Adam <obnox@samba.org>
Thu, 6 Mar 2008 17:03:56 +0000 (18:03 +0100)
This reverts commit 3a0f781352f364ce625a35ffd78257b27d984c47.

This needs more thought.

Setting RPATH like this does not work on all supported
platforms (Linux, Solaris and AIX seem to work, HP-UX,
Tru64 and MacOS don't, MacOS doesn't even seem to have
an rpath at all prior to 10.4).

What is more, rpath also has some bad effects (when
updating libraries, e.g.), so it should not be set
unconditionally.

I will come up with a confiugure mechanism to control this.

For now, just use the LDFLAGS environment variable if
you want to use an rpath.

Sorry for any inconveniences.

Michael

source/Makefile.in

index 9523b8ce9897d5c2f04c405facef5a0f1d95b5c7..7dfa312066cf1f1aafe4fd59138409ac6b2b6e42 100644 (file)
@@ -42,8 +42,8 @@ CPPFLAGS=-DHAVE_CONFIG_H @CPPFLAGS@
 
 EXEEXT=@EXEEXT@
 AR=@AR@
-LDSHFLAGS=@LDSHFLAGS@ @LDFLAGS@ -Wl,-R,$(LIBDIR)
-LDFLAGS=@PIE_LDFLAGS@ @LDFLAGS@ -Wl,-R,$(LIBDIR)
+LDSHFLAGS=@LDSHFLAGS@ @LDFLAGS@
+LDFLAGS=@PIE_LDFLAGS@ @LDFLAGS@
 
 WINBIND_NSS_LDSHFLAGS=@WINBIND_NSS_LDSHFLAGS@ @LDFLAGS@
 AWK=@AWK@