bug-gnu-utils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: gettext-0.11, libtool and DESTDIR


From: Bruno Haible
Subject: Re: gettext-0.11, libtool and DESTDIR
Date: Mon, 4 Feb 2002 12:58:25 +0100 (CET)

Philipp Thomas writes:

> wenn man DESTDIR verwendet, wird libgettextsrc nicht installiert.

Here is a fix.

2002-02-02  Bruno Haible  <address@hidden>

        * ltmain.sh: Add DESTDIR support on ELF systems.

diff -r -c3 --exclude='*.po*' --exclude='*.info*' --exclude='*.html' 
--exclude=Makefile.in --exclude=aclocal.m4 --exclude=configure 
gettext-8/ltmain.sh gettext-9/ltmain.sh
*** gettext-8/ltmain.sh 2001-11-05 11:39:00.000000000 +0100
--- gettext-9/ltmain.sh 2002-02-02 01:04:28.000000000 +0100
***************
*** 1865,1871 ****
              add="-l$name"
            else
              # We cannot seem to hardcode it, guess we'll fake it.
!             add_dir="-L$libdir"
              add="-l$name"
            fi
  
--- 1865,1875 ----
              add="-l$name"
            else
              # We cannot seem to hardcode it, guess we'll fake it.
!             if test "X$installed" = Xyes; then
!               add_dir="-L$libdir"
!             else
!               add_dir="-L$DESTDIR$libdir"
!             fi
              add="-l$name"
            fi
  
***************
*** 4110,4121 ****
--- 4114,4134 ----
        esac
  
        # Add the libdir to current_libdirs if it is the destination.
+       DESTDIR=
        if test "X$destdir" = "X$libdir"; then
          case "$current_libdirs " in
          *" $libdir "*) ;;
          *) current_libdirs="$current_libdirs $libdir" ;;
          esac
        else
+         case "$destdir" in
+           *"$libdir")
+             DESTDIR=`$echo "$destdir" | sed -e 's!'"$libdir"'$!!'`
+             if test "X$destdir" != "X$DESTDIR$libdir"; then
+               DESTDIR=
+             fi
+             ;;
+         esac
          # Note the libdir as a future libdir.
          case "$future_libdirs " in
          *" $libdir "*) ;;
***************
*** 4129,4134 ****
--- 4142,4148 ----
  
        if test -n "$relink_command"; then
          $echo "$modename: warning: relinking \`$file'" 1>&2
+         export DESTDIR
          $show "$relink_command"
          if $run eval "$relink_command"; then :
          else
***************
*** 4136,4141 ****
--- 4150,4156 ----
            continue
          fi
        fi
+       unset DESTDIR
  
        # See the names of the shared library.
        set dummy $library_names



reply via email to

[Prev in Thread] Current Thread [Next in Thread]