+2004-02-12 Tom Yu <tlyu@mit.edu>
+
+ * pre.in (FAKEDEST, FAKEPREFIX, FAKELIBDIR): Support variables for
+ the _RLD_ROOT hack.
+
+ * shlib.conf: For alpha/Tru64 and Irix, construct _RLD_ROOT values
+ pointing to a fake destdir, as well as to the real root directory.
+ Previously, pointing _RLD_ROOT at a non-existent directory and
+ putting everything in LD_LIBRARY_PATH caused other installed
+ utilities with RPATHs which were run by the test suite to fail to
+ run.
+
2004-02-09 Tom Yu <tlyu@mit.edu>
* config.guess: Update from autoconf-2.59.
PROFFLAGS=-pg
RPATH_FLAG='-Wl,-rpath -Wl,'
CC_LINK_SHARED='$(CC) $(PROG_LIBPATH) $(RPATH_FLAG)$(PROG_RPATH) $(CFLAGS) $(LDFLAGS)'
- # Need -oldstyle_liblookup to avoid picking up shared libs from
- # other builds. OSF/1 / Tru64 ld programs look through the entire
- # library path for shared libs prior to looking through the
- # entire library path for static libs.
- CC_LINK_STATIC='$(CC) $(PROG_LIBPATH) -Wl,-oldstyle_liblookup $(CFLAGS) $(LDFLAGS)'
- # $(PROG_RPATH) is here to handle things like a shared tcl library
- RUN_ENV='LD_LIBRARY_PATH=`echo $(PROG_LIBPATH) | sed -e "s/-L//g" -e "s/ /:/g"`:$(PROG_RPATH):/usr/shlib:/usr/ccs/lib:/usr/lib/cmplrs/cc:/usr/lib:/usr/local/lib; export LD_LIBRARY_PATH; _RLD_ROOT=/dev/dummy/d; export _RLD_ROOT;'
+ if test "$krb5_cv_prog_gcc" = yes; then
+ # Really should check for gnu ld vs system ld, too.
+ CC_LINK_STATIC='$(CC) $(PROG_LIBPATH) $(CFLAGS) $(LDFLAGS)'
+ else
+ # Need -oldstyle_liblookup to avoid picking up shared libs from
+ # other builds. OSF/1 / Tru64 ld programs look through the entire
+ # library path for shared libs prior to looking through the
+ # entire library path for static libs.
+ CC_LINK_STATIC='$(CC) $(PROG_LIBPATH) -Wl,-oldstyle_liblookup $(CFLAGS) $(LDFLAGS)'
+ fi
+ # _RLD_ROOT hack needed to repoint "root" directory for purposes
+ # of searching for shared libs, since RPATHs take precedence over
+ # LD_LIBRARY_PATH.
+ RUN_ENV='LD_LIBRARY_PATH=`echo $(PROG_LIBPATH) | sed -e "s/-L//g" -e "s/ /:/g"`$${LD_LIBRARY_PATH+:$$LD_LIBRARY_PATH}; export LD_LIBRARY_PATH; _RLD_ROOT=$(FAKEDEST):$${_RLD_ROOT+$$_RLD_ROOT}$${_RLD_ROOT-/}; export _RLD_ROOT;'
;;
# HPUX *seems* to work under 10.20.
# supported ABIs on Irix, and the precedence of the rpath over
# LD_LIBRARY*_PATH. Like OSF/1, _RLD*_ROOT needs to be set to
# work around this lossage.
- add='`echo $(PROG_LIBPATH) | sed -e "s/-L//g" -e "s/ /:/g"`'
- dummy=/dev/dummmy/d
+ #
# Set the N32 and 64 variables first because the unqualified
# variables affect all three and can cause the sed command to fail.
- RUN_ENV="LD_LIBRARYN32_PATH=$add:/usr/lib32:/usr/lib32/internal:/lib32:/opt/lib32; export LD_LIBRARYN32_PATH; _RLDN32_ROOT=$dummy; export _RLDN32_ROOT; LD_LIBRARY64_PATH=$add:/usr/lib64:/usr/lib64/internal:/lib64:/opt/lib64; export LD_LIBRARY64_PATH; _RLD64_ROOT=$dummy; export _RLD64_ROOT; LD_LIBRARY_PATH=$add:/usr/lib:/usr/lib/internal:/lib:/lib/cmplrs/cc:/usr/lib/cmplrs/cc:/opt/lib; export LD_LIBRARY_PATH; _RLD_ROOT=$dummy; export _RLD_ROOT;"
+ #
+ # This loop is to reduce the clutter a slight bit.
+ add='`echo $(PROG_LIBPATH) | sed -e "s/-L//g" -e "s/ /:/g"`'
+ RUN_ENV=
+ for i in N32 64 ''; do
+ RUN_ENV="${RUN_ENV+ $RUN_ENV}LD_LIBRARY${i}_PATH=$add\$\${LD_LIBRARY${i}_PATH+:\$\$LD_LIBRARY${i}_PATH}; export LD_LIBRARY${i}_PATH;"
+ RUN_ENV="${RUN_ENV} _RLD${i}_ROOT=\$(FAKEDEST):\$\${_RLD${i}_ROOT+\$\${_RLD${i}_ROOT}}\$\${_RLD${i}_ROOT-/}; export _RLD${i}_ROOT;"
+ done
;;
mips-sgi-irix*)
# supported ABIs on Irix, and the precedence of the rpath over
# LD_LIBRARY*_PATH. Like OSF/1, _RLD*_ROOT needs to be set to
# work around this lossage.
- add='`echo $(PROG_LIBPATH) | sed -e "s/-L//g" -e "s/ /:/g"`'
- dummy=/dev/dummmy/d
+ #
# Set the N32 and 64 variables first because the unqualified
# variables affect all three and can cause the sed command to fail.
- RUN_ENV="LD_LIBRARYN32_PATH=$add:/usr/lib32:/usr/lib32/internal:/lib32:/opt/lib32; export LD_LIBRARYN32_PATH; _RLDN32_ROOT=$dummy; export _RLDN32_ROOT; LD_LIBRARY64_PATH=$add:/usr/lib64:/usr/lib64/internal:/lib64:/opt/lib64; export LD_LIBRARY64_PATH; _RLD64_ROOT=$dummy; export _RLD64_ROOT; LD_LIBRARY_PATH=$add:/usr/lib:/usr/lib/internal:/lib:/lib/cmplrs/cc:/usr/lib/cmplrs/cc:/opt/lib; export LD_LIBRARY_PATH; _RLD_ROOT=$dummy; export _RLD_ROOT;"
+ #
+ # This loop is to reduce the clutter a slight bit.
+ add='`echo $(PROG_LIBPATH) | sed -e "s/-L//g" -e "s/ /:/g"`'
+ RUN_ENV=
+ for i in N32 64 ''; do
+ RUN_ENV="${RUN_ENV+ $RUN_ENV}LD_LIBRARY${i}_PATH=$add\$\${LD_LIBRARY${i}_PATH+:\$\$LD_LIBRARY${i}_PATH}; export LD_LIBRARY${i}_PATH;"
+ RUN_ENV="${RUN_ENV} _RLD${i}_ROOT=\$(FAKEDEST):\$\${_RLD${i}_ROOT+\$\${_RLD${i}_ROOT}}\$\${_RLD${i}_ROOT-/}; export _RLD${i}_ROOT;"
+ done
;;
# untested...