libtool-patches
[Top][All Lists]
Advanced

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

Re: [RFT PATCH v4 3/8] teach libtool -L= and -R=


From: Paolo Bonzini
Subject: Re: [RFT PATCH v4 3/8] teach libtool -L= and -R=
Date: Thu, 19 Aug 2010 09:40:11 +0200
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.10) Gecko/20100621 Fedora/3.0.5-1.fc13 Lightning/1.0b2pre Mnenhy/0.8.3 Thunderbird/3.0.5

On 08/19/2010 06:58 AM, Ralf Wildenhues wrote:
+# func_resolve_sysroot PATH
+# Change PATH to an absolute path or replace a leading = with a
+# sysroot.  Store the result into func_resolve_sysroot_result
+func_resolve_sysroot ()
+{
+  func_resolve_sysroot_result=$1
+  case $func_resolve_sysroot_result in
+  [\\/]* | [A-Za-z]:[\\/]*) ;;
+  =*)
+    func_stripname '=' '' "$func_resolve_sysroot_result"
+    func_resolve_sysroot_result=$lt_sysroot$func_stripname_result
+    ;;
+  *)
+    if test -d "$1"; then
+      absdir=`cd "$1"&&  pwd`
+      test -z "$absdir"&&  \
+        func_fatal_error "cannot determine absolute directory name of \`$dir'"
+      func_resolve_sysroot_result=`cd "$dir"&&  pwd`
+    else
+      func_dirname_and_basename "$1" "" "."
+      absdir=`cd "$func_dirname_result"&&  pwd`
+      test -z "$absdir"&&  \
+        func_fatal_error "cannot determine absolute directory name of 
\`$func_dirname_result'"
+      func_resolve_sysroot_result="$absdir/$func_basename_result"
+    fi
+    ;;
+  esac
+}

Why does this function absolutize paths that have nothing to do with
sysroot, even in-tree deplib paths?
Is there a deeper reason in this?  If yes, there should probably be a
test which is fixed by it.

It's a bug, I think I did it to simplify other places but this was wrong as the AIX case shows. I had the same idea more or less, but I didn't have time to make a patch.

Paolo



reply via email to

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