[Autosec-devel] sonar aclocal.m4,1.9,1.10 config.h.in,1.22,1.23 config.sub,1.1,1.2 configure,1.35,1.
Brought to you by:
red0x
From: red0x <re...@us...> - 2004-04-08 21:19:10
|
Update of /cvsroot/autosec/sonar In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12183 Modified Files: aclocal.m4 config.h.in config.sub configure configure.in ltmain.sh Log Message: Added a configure check for strndup Index: config.h.in =================================================================== RCS file: /cvsroot/autosec/sonar/config.h.in,v retrieving revision 1.22 retrieving revision 1.23 diff -C2 -d -r1.22 -r1.23 *** config.h.in 31 Jan 2004 04:41:52 -0000 1.22 --- config.h.in 8 Apr 2004 21:05:53 -0000 1.23 *************** *** 107,110 **** --- 107,113 ---- #undef HAVE_STRING_H + /* Define to 1 if you have the `strndup' function. */ + #undef HAVE_STRNDUP + /* Define to 1 if you have the <syslog.h> header file. */ #undef HAVE_SYSLOG_H Index: configure =================================================================== RCS file: /cvsroot/autosec/sonar/configure,v retrieving revision 1.35 retrieving revision 1.36 diff -C2 -d -r1.35 -r1.36 *** configure 6 Feb 2004 06:20:51 -0000 1.35 --- configure 8 Apr 2004 21:05:53 -0000 1.36 *************** *** 5893,5896 **** --- 5893,5920 ---- ;; + linux*) + if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + supports_anon_versioning=no + case `$LD -v 2>/dev/null` in + *\ 01.* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 + *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... + *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... + *\ 2.11.*) ;; # other 2.11 versions + *) supports_anon_versioning=yes ;; + esac + if test $supports_anon_versioning = yes; then + archive_expsym_cmds='$echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + $echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + else + $archive_expsym_cmds="$archive_cmds" + fi + else + ld_shlibs=no + fi + ;; + *) if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then *************** *** 6687,6691 **** case "$host_cpu" in x86_64*) ! echo '#line 6689 "configure"' > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 --- 6711,6715 ---- case "$host_cpu" in x86_64*) ! echo '#line 6713 "configure"' > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 *************** *** 7435,7439 **** lt_status=$lt_dlunknown cat > conftest.$ac_ext <<EOF ! #line 7437 "configure" #include "confdefs.h" --- 7459,7463 ---- lt_status=$lt_dlunknown cat > conftest.$ac_ext <<EOF ! #line 7461 "configure" #include "confdefs.h" *************** *** 7533,7537 **** lt_status=$lt_dlunknown cat > conftest.$ac_ext <<EOF ! #line 7535 "configure" #include "confdefs.h" --- 7557,7561 ---- lt_status=$lt_dlunknown cat > conftest.$ac_ext <<EOF ! #line 7559 "configure" #include "confdefs.h" *************** *** 11430,11434 **** ! for ac_func in getcwd gethostbyaddr gethostbyname gethostname gettimeofday inet_ntoa memmove memset select socket strchr strerror do as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` --- 11454,11459 ---- ! ! for ac_func in getcwd gethostbyaddr gethostbyname gethostname gettimeofday inet_ntoa memmove memset select socket strchr strerror strndup do as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` Index: configure.in =================================================================== RCS file: /cvsroot/autosec/sonar/configure.in,v retrieving revision 1.32 retrieving revision 1.33 diff -C2 -d -r1.32 -r1.33 *** configure.in 6 Feb 2004 06:20:50 -0000 1.32 --- configure.in 8 Apr 2004 21:05:54 -0000 1.33 *************** *** 72,76 **** AC_FUNC_STAT AC_FUNC_VPRINTF ! AC_CHECK_FUNCS([getcwd gethostbyaddr gethostbyname gethostname gettimeofday inet_ntoa memmove memset select socket strchr strerror]) --- 72,76 ---- AC_FUNC_STAT AC_FUNC_VPRINTF ! AC_CHECK_FUNCS([getcwd gethostbyaddr gethostbyname gethostname gettimeofday inet_ntoa memmove memset select socket strchr strerror strndup]) Index: aclocal.m4 =================================================================== RCS file: /cvsroot/autosec/sonar/aclocal.m4,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** aclocal.m4 24 Sep 2003 19:57:15 -0000 1.9 --- aclocal.m4 8 Apr 2004 21:05:53 -0000 1.10 *************** *** 2243,2246 **** --- 2243,2270 ---- ;; + linux*) + if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + supports_anon_versioning=no + case `$LD -v 2>/dev/null` in + *\ [01].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 + *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... + *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... + *\ 2.11.*) ;; # other 2.11 versions + *) supports_anon_versioning=yes ;; + esac + if test $supports_anon_versioning = yes; then + archive_expsym_cmds='$echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + $echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + else + $archive_expsym_cmds="$archive_cmds" + fi + else + ld_shlibs=no + fi + ;; + *) if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then Index: config.sub =================================================================== RCS file: /cvsroot/autosec/sonar/config.sub,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** config.sub 14 Oct 2003 23:38:59 -0000 1.1 --- config.sub 8 Apr 2004 21:05:53 -0000 1.2 *************** *** 368,371 **** --- 368,374 ---- os=-bsd ;; + amd64-*) + basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; amdahl) basic_machine=580-amdahl Index: ltmain.sh =================================================================== RCS file: /cvsroot/autosec/sonar/ltmain.sh,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** ltmain.sh 14 Oct 2003 23:38:59 -0000 1.1 --- ltmain.sh 8 Apr 2004 21:05:54 -0000 1.2 *************** *** 60,64 **** PACKAGE=libtool VERSION=1.4.3 ! TIMESTAMP=" (1.922.2.110 2002/10/23 01:39:54)" default_mode= --- 60,64 ---- PACKAGE=libtool VERSION=1.4.3 ! TIMESTAMP=" (1.922.2.111 2002/10/23 02:54:36)" default_mode= *************** *** 220,234 **** fi - # Mandrake: (gc) It's bad to link C++ code with GCC, so we need to use the compiler name if provided - if test "$mode" = link && test -n "$archive_cmds" && test -x "/usr/bin/perl"; then - case $nonopt in - *cc | *++ | gcc* | *-gcc* | egcs*) - archive_cmds=`echo $archive_cmds | perl -pe 's/^\S+\s+//'` - archive_cmds="$nonopt $archive_cmds" - archive_expsym_cmds=`echo $archive_expsym_cmds | perl -pe 's/^\S+\s+//'` - archive_expsym_cmds="$nonopt $archive_expsym_cmds" - esac - fi - # If this variable is set in any of the actions, the command in it # will be execed at the end. This prevents here-documents from being --- 220,223 ---- *************** *** 783,786 **** --- 772,776 ---- dllsearchpath= lib_search_path=`pwd` + inst_prefix_dir= avoid_version=no *************** *** 913,916 **** --- 903,911 ---- continue ;; + inst_prefix) + inst_prefix_dir="$arg" + prev= + continue + ;; release) release="-$arg" *************** *** 1014,1017 **** --- 1009,1017 ---- ;; + -inst-prefix-dir) + prev=inst_prefix + continue + ;; + # The native IRIX linker understands -LANG:*, -LIST:* and -LNO:* # so, if we see these flags be careful not to treat them like -L *************** *** 1215,1218 **** --- 1215,1223 ---- ;; + -Kthread | -mthreads | -mt | -pthread | -pthreads | -threads | -qthreaded | -kthread ) + compiler_flags="$compiler_flags $arg" + continue + ;; + # Some other compiler flag. -* | +*) *************** *** 1394,1398 **** esac for pass in $passes; do ! if test $linkmode = prog; then # Determine which files to process case $pass in --- 1399,1403 ---- esac for pass in $passes; do ! if test "$linkmode" = prog; then # Determine which files to process case $pass in *************** *** 1411,1419 **** case $deplib in -l*) ! if test $linkmode = oldlib && test $linkmode = obj; then $echo "$modename: warning: \`-l' is ignored for archives/objects: $deplib" 1>&2 continue fi ! if test $pass = conv; then deplibs="$deplib $deplibs" continue --- 1416,1424 ---- case $deplib in -l*) ! if test "$linkmode" = oldlib && test "$linkmode" = obj; then $echo "$modename: warning: \`-l' is ignored for archives/objects: $deplib" 1>&2 continue fi ! if test "$pass" = conv; then deplibs="$deplib $deplibs" continue *************** *** 1435,1439 **** else deplibs="$deplib $deplibs" ! test $linkmode = lib && newdependency_libs="$deplib $newdependency_libs" fi continue --- 1440,1444 ---- else deplibs="$deplib $deplibs" ! test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" fi continue *************** *** 1444,1457 **** lib) deplibs="$deplib $deplibs" ! test $pass = conv && continue newdependency_libs="$deplib $newdependency_libs" newlib_search_path="$newlib_search_path "`$echo "X$deplib" | $Xsed -e 's/^-L//'` ;; prog) ! if test $pass = conv; then deplibs="$deplib $deplibs" continue fi ! if test $pass = scan; then deplibs="$deplib $deplibs" newlib_search_path="$newlib_search_path "`$echo "X$deplib" | $Xsed -e 's/^-L//'` --- 1449,1462 ---- lib) deplibs="$deplib $deplibs" ! test "$pass" = conv && continue newdependency_libs="$deplib $newdependency_libs" newlib_search_path="$newlib_search_path "`$echo "X$deplib" | $Xsed -e 's/^-L//'` ;; prog) ! if test "$pass" = conv; then deplibs="$deplib $deplibs" continue fi ! if test "$pass" = scan; then deplibs="$deplib $deplibs" newlib_search_path="$newlib_search_path "`$echo "X$deplib" | $Xsed -e 's/^-L//'` *************** *** 1468,1472 **** ;; # -L -R*) ! if test $pass = link; then dir=`$echo "X$deplib" | $Xsed -e 's/^-R//'` # Make sure the xrpath contains only unique directories. --- 1473,1477 ---- ;; # -L -R*) ! if test "$pass" = link; then dir=`$echo "X$deplib" | $Xsed -e 's/^-R//'` # Make sure the xrpath contains only unique directories. *************** *** 1481,1485 **** *.la) lib="$deplib" ;; *.$libext) ! if test $pass = conv; then deplibs="$deplib $deplibs" continue --- 1486,1490 ---- *.la) lib="$deplib" ;; *.$libext) ! if test "$pass" = conv; then deplibs="$deplib $deplibs" continue *************** *** 1504,1508 **** ;; prog) ! if test $pass != link; then deplibs="$deplib $deplibs" else --- 1509,1513 ---- ;; prog) ! if test "$pass" != link; then deplibs="$deplib $deplibs" else *************** *** 1515,1519 **** ;; # *.$libext *.lo | *.$objext) ! if test $pass = dlpreopen || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then # If there is no dlopen support or we're linking statically, # we need to preload. --- 1520,1524 ---- ;; # *.$libext *.lo | *.$objext) ! if test "$pass" = dlpreopen || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then # If there is no dlopen support or we're linking statically, # we need to preload. *************** *** 1531,1535 **** ;; esac # case $deplib ! if test $found = yes || test -f "$lib"; then : else $echo "$modename: cannot find the library \`$lib'" 1>&2 --- 1536,1540 ---- ;; esac # case $deplib ! if test "$found" = yes || test -f "$lib"; then : else $echo "$modename: cannot find the library \`$lib'" 1>&2 *************** *** 1565,1569 **** if test "$linkmode,$pass" = "lib,link" || test "$linkmode,$pass" = "prog,scan" || ! { test $linkmode = oldlib && test $linkmode = obj; }; then # Add dl[pre]opened files of deplib test -n "$dlopen" && dlfiles="$dlfiles $dlopen" --- 1570,1574 ---- if test "$linkmode,$pass" = "lib,link" || test "$linkmode,$pass" = "prog,scan" || ! { test "$linkmode" = oldlib && test "$linkmode" = obj; }; then # Add dl[pre]opened files of deplib test -n "$dlopen" && dlfiles="$dlfiles $dlopen" *************** *** 1571,1575 **** fi ! if test $pass = conv; then # Only check for convenience libraries deplibs="$lib $deplibs" --- 1576,1580 ---- fi ! if test "$pass" = conv; then # Only check for convenience libraries deplibs="$lib $deplibs" *************** *** 1592,1596 **** tmp_libs="$tmp_libs $deplib" done ! elif test $linkmode != prog && test $linkmode != lib; then $echo "$modename: \`$lib' is not a convenience library" 1>&2 exit 1 --- 1597,1601 ---- tmp_libs="$tmp_libs $deplib" done ! elif test "$linkmode" != prog && test "$linkmode" != lib; then $echo "$modename: \`$lib' is not a convenience library" 1>&2 exit 1 *************** *** 1610,1614 **** # This library was specified with -dlopen. ! if test $pass = dlopen; then if test -z "$libdir"; then $echo "$modename: cannot -dlopen a convenience library: \`$lib'" 1>&2 --- 1615,1619 ---- # This library was specified with -dlopen. ! if test "$pass" = dlopen; then if test -z "$libdir"; then $echo "$modename: cannot -dlopen a convenience library: \`$lib'" 1>&2 *************** *** 1659,1663 **** # This library was specified with -dlpreopen. ! if test $pass = dlpreopen; then if test -z "$libdir"; then $echo "$modename: cannot -dlpreopen a convenience library: \`$lib'" 1>&2 --- 1664,1668 ---- # This library was specified with -dlpreopen. ! if test "$pass" = dlpreopen; then if test -z "$libdir"; then $echo "$modename: cannot -dlpreopen a convenience library: \`$lib'" 1>&2 *************** *** 1678,1682 **** if test -z "$libdir"; then # Link the convenience library ! if test $linkmode = lib; then deplibs="$dir/$old_library $deplibs" elif test "$linkmode,$pass" = "prog,link"; then --- 1683,1687 ---- if test -z "$libdir"; then # Link the convenience library ! if test "$linkmode" = lib; then deplibs="$dir/$old_library $deplibs" elif test "$linkmode,$pass" = "prog,link"; then *************** *** 1689,1693 **** fi ! if test $linkmode = prog && test $pass != link; then newlib_search_path="$newlib_search_path $ladir" deplibs="$lib $deplibs" --- 1694,1698 ---- fi ! if test "$linkmode" = prog && test "$pass" != link; then newlib_search_path="$newlib_search_path $ladir" deplibs="$lib $deplibs" *************** *** 1705,1709 **** esac # Need to link against all dependency_libs? ! if test $linkalldeplibs = yes; then deplibs="$deplib $deplibs" else --- 1710,1714 ---- esac # Need to link against all dependency_libs? ! if test "$linkalldeplibs" = yes; then deplibs="$deplib $deplibs" else *************** *** 1728,1732 **** if test "$linkmode,$pass" = "prog,link" || ! { test $linkmode = lib && test $hardcode_into_libs = yes; }; then # Hardcode the library path. # Skip directories that are in the system default run-time --- 1733,1737 ---- if test "$linkmode,$pass" = "prog,link" || ! { test "$linkmode" = lib && test "$hardcode_into_libs" = yes; }; then # Hardcode the library path. # Skip directories that are in the system default run-time *************** *** 1750,1754 **** ;; esac ! if test $linkmode = prog; then # We need to hardcode the library path if test -n "$shlibpath_var"; then --- 1755,1759 ---- ;; esac ! if test "$linkmode" = prog; then # We need to hardcode the library path if test -n "$shlibpath_var"; then *************** *** 1834,1838 **** fi # test -n $old_archive_from_expsyms_cmds ! if test $linkmode = prog || test "$mode" != relink; then add_shlibpath= add_dir= --- 1839,1843 ---- fi # test -n $old_archive_from_expsyms_cmds ! if test "$linkmode" = prog || test "$mode" != relink; then add_shlibpath= add_dir= *************** *** 1883,1887 **** esac fi ! if test $linkmode = prog; then test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs" test -n "$add" && compile_deplibs="$add $compile_deplibs" --- 1888,1892 ---- esac fi ! if test "$linkmode" = prog; then test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs" test -n "$add" && compile_deplibs="$add $compile_deplibs" *************** *** 1900,1904 **** fi ! if test $linkmode = prog || test "$mode" = relink; then add_shlibpath= add_dir= --- 1905,1909 ---- fi ! if test "$linkmode" = prog || test "$mode" = relink; then add_shlibpath= add_dir= *************** *** 1908,1912 **** add="$libdir/$linklib" elif test "$hardcode_minus_L" = yes; then ! add_dir="-L$libdir" add="-l$name" elif test "$hardcode_shlibpath_var" = yes; then --- 1913,1926 ---- add="$libdir/$linklib" elif test "$hardcode_minus_L" = yes; then ! # Try looking first in the location we're being installed to. ! add_dir= ! if test -n "$inst_prefix_dir"; then ! case "$libdir" in ! [\\/]*) ! add_dir="-L$inst_prefix_dir$libdir" ! ;; ! esac ! fi ! add_dir="$add_dir -L$libdir" add="-l$name" elif test "$hardcode_shlibpath_var" = yes; then *************** *** 1918,1926 **** else # We cannot seem to hardcode it, guess we'll fake it. ! add_dir="-L$libdir" add="-l$name" fi ! if test $linkmode = prog; then test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs" test -n "$add" && finalize_deplibs="$add $finalize_deplibs" --- 1932,1949 ---- else # We cannot seem to hardcode it, guess we'll fake it. ! # Try looking first in the location we're being installed to. ! add_dir= ! if test -n "$inst_prefix_dir"; then ! case "$libdir" in ! [\\/]*) ! add_dir="-L$inst_prefix_dir$libdir" ! ;; ! esac ! fi ! add_dir="$add_dir -L$libdir" add="-l$name" fi ! if test "$linkmode" = prog; then test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs" test -n "$add" && finalize_deplibs="$add $finalize_deplibs" *************** *** 1930,1934 **** fi fi ! elif test $linkmode = prog; then if test "$alldeplibs" = yes && { test "$deplibs_check_method" = pass_all || --- 1953,1957 ---- fi fi ! elif test "$linkmode" = prog; then if test "$alldeplibs" = yes && { test "$deplibs_check_method" = pass_all || *************** *** 1990,1997 **** fi # link shared/static library? ! if test $linkmode = lib; then if test -n "$dependency_libs" && ! { test $hardcode_into_libs != yes || test $build_old_libs = yes || ! test $link_static = yes; }; then # Extract -R from dependency_libs temp_deplibs= --- 2013,2020 ---- fi # link shared/static library? ! if test "$linkmode" = lib; then if test -n "$dependency_libs" && ! { test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes || ! test "$link_static" = yes; }; then # Extract -R from dependency_libs temp_deplibs= *************** *** 2024,2028 **** done ! if test $link_all_deplibs != no; then # Add the search paths of all dependency libraries for deplib in $dependency_libs; do --- 2047,2051 ---- done ! if test "$link_all_deplibs" != no; then # Add the search paths of all dependency libraries for deplib in $dependency_libs; do *************** *** 2067,2071 **** fi # linkmode = lib done # for deplib in $libs ! if test $pass = dlpreopen; then # Link the dlpreopened libraries before other libraries for deplib in $save_deplibs; do --- 2090,2094 ---- fi # linkmode = lib done # for deplib in $libs ! if test "$pass" = dlpreopen; then # Link the dlpreopened libraries before other libraries for deplib in $save_deplibs; do *************** *** 2073,2079 **** done fi ! if test $pass != dlopen; then ! test $pass != scan && dependency_libs="$newdependency_libs" ! if test $pass != conv; then # Make sure lib_search_path contains only unique directories. lib_search_path= --- 2096,2102 ---- done fi ! if test "$pass" != dlopen; then ! test "$pass" != scan && dependency_libs="$newdependency_libs" ! if test "$pass" != conv; then # Make sure lib_search_path contains only unique directories. lib_search_path= *************** *** 2133,2137 **** fi done # for pass ! if test $linkmode = prog; then dlfiles="$newdlfiles" dlprefiles="$newdlprefiles" --- 2156,2160 ---- fi done # for pass ! if test "$linkmode" = prog; then dlfiles="$newdlfiles" dlprefiles="$newdlprefiles" *************** *** 2251,2255 **** # Check that each of the things are valid numbers. case $current in ! 0 | [1-9] | [1-9][0-9] | [1-9][0-9][0-9]) ;; *) $echo "$modename: CURRENT \`$current' is not a nonnegative integer" 1>&2 --- 2274,2278 ---- # Check that each of the things are valid numbers. case $current in ! [0-9]*) ;; *) $echo "$modename: CURRENT \`$current' is not a nonnegative integer" 1>&2 *************** *** 2260,2264 **** case $revision in ! 0 | [1-9] | [1-9][0-9] | [1-9][0-9][0-9]) ;; *) $echo "$modename: REVISION \`$revision' is not a nonnegative integer" 1>&2 --- 2283,2287 ---- case $revision in ! [0-9]*) ;; *) $echo "$modename: REVISION \`$revision' is not a nonnegative integer" 1>&2 *************** *** 2269,2273 **** case $age in ! 0 | [1-9] | [1-9][0-9] | [1-9][0-9][0-9]) ;; *) $echo "$modename: AGE \`$age' is not a nonnegative integer" 1>&2 --- 2292,2296 ---- case $age in ! [0-9]*) ;; *) $echo "$modename: AGE \`$age' is not a nonnegative integer" 1>&2 *************** *** 2445,2449 **** esac done ! if test $hardcode_into_libs != yes || test $build_old_libs = yes; then dependency_libs="$temp_xrpath $dependency_libs" fi --- 2468,2472 ---- esac done ! if test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes; then dependency_libs="$temp_xrpath $dependency_libs" fi *************** *** 2488,2492 **** *) # Add libc to deplibs on all other systems if necessary. ! if test $build_libtool_need_lc = "yes"; then deplibs="$deplibs -lc" fi --- 2511,2515 ---- *) # Add libc to deplibs on all other systems if necessary. ! if test "$build_libtool_need_lc" = "yes"; then deplibs="$deplibs -lc" fi *************** *** 2760,2764 **** echo "*** or is declared to -dlopen it." ! if test $allow_undefined = no; then echo echo "*** Since this library must not contain undefined symbols," --- 2783,2787 ---- echo "*** or is declared to -dlopen it." ! if test "$allow_undefined" = no; then echo echo "*** Since this library must not contain undefined symbols," *************** *** 2787,2791 **** # Test again, we may have decided not to build it any more if test "$build_libtool_libs" = yes; then ! if test $hardcode_into_libs = yes; then # Hardcode the library paths hardcode_libdirs= --- 2810,2814 ---- # Test again, we may have decided not to build it any more if test "$build_libtool_libs" = yes; then ! if test "$hardcode_into_libs" = yes; then # Hardcode the library paths hardcode_libdirs= *************** *** 3495,3499 **** fi ! if test $need_relink = no || test "$build_libtool_libs" != yes; then # Replace the output file specification. compile_command=`$echo "X$compile_command" | $Xsed -e 's%@OUTPUT@%'"$output"'%g'` --- 3518,3522 ---- fi ! if test "$need_relink" = no || test "$build_libtool_libs" != yes; then # Replace the output file specification. compile_command=`$echo "X$compile_command" | $Xsed -e 's%@OUTPUT@%'"$output"'%g'` *************** *** 3950,3954 **** done # Quote the link command for shipping. ! relink_command="(cd `pwd`; $SHELL $0 --mode=relink $libtool_args)" relink_command=`$echo "X$relink_command" | $Xsed -e "$sed_quote_subst"` --- 3973,3977 ---- done # Quote the link command for shipping. ! relink_command="(cd `pwd`; $SHELL $0 --mode=relink $libtool_args @inst_prefix_dir@)" relink_command=`$echo "X$relink_command" | $Xsed -e "$sed_quote_subst"` *************** *** 4081,4085 **** # Directory that this library needs to be installed in: libdir='$install_libdir'" ! if test "$installed" = no && test $need_relink = yes; then $echo >> $output "\ relink_command=\"$relink_command\"" --- 4104,4108 ---- # Directory that this library needs to be installed in: libdir='$install_libdir'" ! if test "$installed" = no && test "$need_relink" = yes; then $echo >> $output "\ relink_command=\"$relink_command\"" *************** *** 4292,4295 **** --- 4315,4336 ---- if test -n "$relink_command"; then + # Determine the prefix the user has applied to our future dir. + inst_prefix_dir=`$echo "$destdir" | sed "s%$libdir\$%%"` + + # Don't allow the user to place us outside of our expected + # location b/c this prevents finding dependent libraries that + # are installed to the same prefix. + if test "$inst_prefix_dir" = "$destdir"; then + $echo "$modename: error: cannot install \`$file' to a directory not ending in $libdir" 1>&2 + exit 1 + fi + + if test -n "$inst_prefix_dir"; then + # Stick the inst_prefix_dir data into the link command. + relink_command=`$echo "$relink_command" | sed "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"` + else + relink_command=`$echo "$relink_command" | sed "s%@inst_prefix_dir@%%"` + fi + $echo "$modename: warning: relinking \`$file'" 1>&2 $show "$relink_command" *************** *** 4297,4301 **** else $echo "$modename: error: relink \`$file' with the above command before installing it" 1>&2 ! continue fi fi --- 4338,4342 ---- else $echo "$modename: error: relink \`$file' with the above command before installing it" 1>&2 ! exit 1 fi fi *************** *** 4460,4464 **** tmpdir="/tmp" test -n "$TMPDIR" && tmpdir="$TMPDIR" ! tmpdir="$tmpdir/libtool-$$" if $mkdir -p "$tmpdir" && chmod 700 "$tmpdir"; then : else --- 4501,4509 ---- tmpdir="/tmp" test -n "$TMPDIR" && tmpdir="$TMPDIR" ! tmpdir=`mktemp -d $tmpdir/libtool-XXXXXX 2> /dev/null` ! if test $? = 0 ; then : ! else ! tmpdir="$tmpdir/libtool-$$" ! fi if $mkdir -p "$tmpdir" && chmod 700 "$tmpdir"; then : else *************** *** 4801,4808 **** fi name=`$echo "X$file" | $Xsed -e 's%^.*/%%'` ! test $mode = uninstall && objdir="$dir" # Remember objdir for removal later, being careful to avoid duplicates ! if test $mode = clean; then case " $rmdirs " in *" $objdir "*) ;; --- 4846,4853 ---- fi name=`$echo "X$file" | $Xsed -e 's%^.*/%%'` ! test "$mode" = uninstall && objdir="$dir" # Remember objdir for removal later, being careful to avoid duplicates ! if test "$mode" = clean; then case " $rmdirs " in *" $objdir "*) ;; *************** *** 4836,4842 **** done test -n "$old_library" && rmfiles="$rmfiles $objdir/$old_library" ! test $mode = clean && rmfiles="$rmfiles $objdir/$name $objdir/${name}i" ! if test $mode = uninstall; then if test -n "$library_names"; then # Do each command in the postuninstall commands. --- 4881,4887 ---- done test -n "$old_library" && rmfiles="$rmfiles $objdir/$old_library" ! test "$mode" = clean && rmfiles="$rmfiles $objdir/$name $objdir/${name}i" ! if test "$mode" = uninstall; then if test -n "$library_names"; then # Do each command in the postuninstall commands. *************** *** 4882,4886 **** *) # Do a test to see if this is a libtool program. ! if test $mode = clean && (${SED} -e '4q' $file | egrep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then relink_command= --- 4927,4931 ---- *) # Do a test to see if this is a libtool program. ! if test "$mode" = clean && (${SED} -e '4q' $file | egrep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then relink_command= |