]> git.ipfire.org Git - thirdparty/libtool.git/commitdiff
* NEWS: support for installing stripped libraries using GNU strip
authorThomas Tanner <tanner@ffii.org>
Tue, 25 May 1999 16:05:50 +0000 (16:05 +0000)
committerThomas Tanner <tanner@gmx.de>
Tue, 25 May 1999 16:05:50 +0000 (16:05 +0000)
* ltconfig.in: set deplibs_check_method=pass_all on FreeBSD,
  Linux and Solaris since no one can reproduce the famous deplibs
  bug
* ltmain.in: preserve $CC (reported by Tom Tromey),
  strip libraries using GNU strip if it's available and the
  -s flag was passed to "install"

ChangeLog
ltmain.in

index 84c1d8d69d352086f90160823e96d361ac650580..92c97616b3ea92c68a92404765a52f9471c20c0d 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+1999-05-24 Thomas Tanner  <tanner@ffii.org>
+
+       * NEWS: support for installing stripped libraries using GNU strip 
+       * ltconfig.in: set deplibs_check_method=pass_all on FreeBSD,
+         Linux and Solaris since no one can reproduce the famous deplibs
+         bug
+       * ltmain.in: preserve $CC (reported by Tom Tromey),
+         strip libraries using GNU strip if it's available and the
+         -s flag was passed to "install"
+
 1999-05-23  Alexandre Oliva  <oliva@dcc.unicamp.br>
 
        * doc/PLATFORMS: Release 1.3.1 passes on GNU Hurd/x86.
index b58f7850017ee98f82988684a1ee00d06a7ee1cf..38afedbaab14cf8112cf89fa71750b88d3d3e768 100644 (file)
--- a/ltmain.in
+++ b/ltmain.in
@@ -611,8 +611,6 @@ compiler."
   # libtool link mode
   link)
     modename="$modename: link"
-    C_compiler="$CC" # save it, to compile generated C sources
-    CC="$nonopt"
     case "$host" in
     *-*-cygwin* | *-*-mingw* | *-*-os2*)
       # It is impossible to link a dll without this setting, and
@@ -1984,7 +1982,7 @@ compiler."
          int main() { return 0; }
 EOF
          $rm conftest
-         $C_compiler -o conftest conftest.c $deplibs
+         $CC -o conftest conftest.c $deplibs
          if test $? -eq 0 ; then
            ldd_output=`ldd conftest`
            for i in $deplibs; do
@@ -2017,7 +2015,7 @@ EOF
             # If $name is empty we are operating on a -L argument.
              if test "$name" != "" ; then
                $rm conftest
-               $C_compiler -o conftest conftest.c $i
+               $CC -o conftest conftest.c $i
                # Did it work?
                if test $? -eq 0 ; then
                  ldd_output=`ldd conftest`
@@ -3119,8 +3117,8 @@ static const void *lt_preloaded_setup() {
          esac
 
          # Now compile the dynamic symbol file.
-         $show "(cd $output_objdir && $C_compiler -c$no_builtin_flag$pic_flag_for_symtable \"$dlsyms\")"
-         $run eval '(cd $output_objdir && $C_compiler -c$no_builtin_flag$pic_flag_for_symtable "$dlsyms")' || exit $?
+         $show "(cd $output_objdir && $CC -c$no_builtin_flag$pic_flag_for_symtable \"$dlsyms\")"
+         $run eval '(cd $output_objdir && $CC -c$no_builtin_flag$pic_flag_for_symtable "$dlsyms")' || exit $?
 
          # Clean up the generated files.
          $show "$rm $output_objdir/$dlsyms $nlist ${nlist}S ${nlist}T"
@@ -3655,6 +3653,7 @@ libdir='$install_libdir'\
     install_type=
     isdir=no
     stripme=
+    gnustrip=no
     for arg
     do
       if test -n "$dest"; then
@@ -3671,6 +3670,7 @@ libdir='$install_libdir'\
       -o) prev="-o" ;;
       -s)
        stripme=" -s"
+       strip -V | grep "GNU strip" >/dev/null && gnustrip=yes
        continue
        ;;
       -*) ;;
@@ -3817,6 +3817,10 @@ libdir='$install_libdir'\
          $show "$install_prog $dir/$realname $destdir/$realname"
          $run eval "$install_prog $dir/$realname $destdir/$realname" || exit $?
          test "X$dlname" = "X$realname" && dlname=
+         if test $gnustrip = yes; then
+           $show "strip --strip-unneeded $destdir/$realname"
+           $run eval "strip --strip-unneeded $destdir/$realname" || exit $?
+         fi
 
          if test $# -gt 0; then
            # Delete the old symlinks, and create new ones.
@@ -3994,6 +3998,11 @@ libdir='$install_libdir'\
       $show "$install_prog $file $oldlib"
       $run eval "$install_prog \$file \$oldlib" || exit $?
 
+      if test $gnustrip = yes; then
+       $show "strip --strip-debug $oldlib"
+       $run eval "strip --strip-debug $oldlib" || exit $?
+      fi
+      
       # Do each command in the postinstall commands.
       eval cmds=\"$old_postinstall_cmds\"
       IFS="${IFS=      }"; save_ifs="$IFS"; IFS='~'