Bugzilla Bug 259945: Mozilla should use $ORIGIN instead of LD_LIBRARY_PATH

to locate shared libraries on Solaris whenever possible.  The patch is
contributed by Brian Lu of Sun <brian.lu@sun.com>.  r=wtc,bryner.
sr=neil.parkwaycc.co.uk.
Modified Files: configure.in build/unix/run-mozilla.sh
This commit is contained in:
wtchang%redhat.com 2005-10-17 17:21:17 +00:00
Родитель edf8c5e56c
Коммит 6f0953f395
2 изменённых файлов: 12 добавлений и 3 удалений

Просмотреть файл

@ -328,7 +328,14 @@ if [ -z "$MRE_HOME" ]; then
fi
##
## Set LD_LIBRARY_PATH
LD_LIBRARY_PATH=${MOZ_DIST_BIN}:${MOZ_DIST_BIN}/plugins:${MRE_HOME}${LD_LIBRARY_PATH+":$LD_LIBRARY_PATH"}
## On Solaris we use $ORIGIN instead of LD_LIBRARY_PATH unless
## $MOZ_PROGRAM is a symbolic link, in this case we need to set
## LD_LIBRARY_PATH because $ORIGIN doesn't work on a symbolic link.
if [ `uname -s` != "SunOS" -o -h "$MOZ_PROGRAM" ]
then
LD_LIBRARY_PATH=${MOZ_DIST_BIN}:${MOZ_DIST_BIN}/plugins:${MRE_HOME}${LD_LIBRARY_PATH+":$LD_LIBRARY_PATH"}
fi
if [ -n "$LD_LIBRARYN32_PATH" ]
then
LD_LIBRARYN32_PATH=${MOZ_DIST_BIN}:${MOZ_DIST_BIN}/plugins:${MRE_HOME}${LD_LIBRARYN32_PATH+":$LD_LIBRARYN32_PATH"}

Просмотреть файл

@ -1987,8 +1987,10 @@ dnl the qsort routine under solaris is faulty
NS_USE_NATIVE=1
AC_DEFINE(NSCAP_DISABLE_DEBUG_PTR_TYPES)
CFLAGS="$CFLAGS -xstrconst -xbuiltin=%all"
CXXFLAGS="$CXXFLAGS -xbuiltin=%all -features=tmplife"
LDFLAGS="-xildoff -zlazyload -zcombreloc $LDFLAGS"
CXXFLAGS="$CXXFLAGS -xbuiltin=%all -features=tmplife -norunpath"
# $ORIGIN/.. is for shared libraries under components/ to locate shared
# libraries one level up (e.g. libnspr4.so)
LDFLAGS="-xildoff -zlazyload -zcombreloc $LDFLAGS -R '\$\$ORIGIN:\$\$ORIGIN/..'"
MOZ_OPTIMIZE_FLAGS="-xO4"
MKSHLIB='$(CXX) $(CXXFLAGS) $(DSO_PIC_FLAGS) $(DSO_LDOPTS) -o $@'
MKCSHLIB='$(CC) $(CFLAGS) $(DSO_PIC_FLAGS) -G -Wl,-z -Wl,muldefs -o $@'