SOURCES: binutils-libtool-relink.patch - updated (from libtool)

qboosh qboosh at pld-linux.org
Fri Jun 22 08:09:43 CEST 2007


Author: qboosh                       Date: Fri Jun 22 06:09:43 2007 GMT
Module: SOURCES                       Tag: HEAD
---- Log message:
- updated (from libtool)

---- Files affected:
SOURCES:
   binutils-libtool-relink.patch (1.1 -> 1.2) 

---- Diffs:

================================================================
Index: SOURCES/binutils-libtool-relink.patch
diff -u SOURCES/binutils-libtool-relink.patch:1.1 SOURCES/binutils-libtool-relink.patch:1.2
--- SOURCES/binutils-libtool-relink.patch:1.1	Sun Jun  1 12:51:53 2003
+++ SOURCES/binutils-libtool-relink.patch	Fri Jun 22 08:09:38 2007
@@ -1,72 +1,14 @@
---- binutils-2.14.90.0.4/ltmain.sh.orig	2002-03-22 23:06:16.000000000 +0100
-+++ binutils-2.14.90.0.4/ltmain.sh	2003-06-01 10:44:39.000000000 +0200
-@@ -829,6 +829,7 @@
-     linker_flags=
-     dllsearchpath=
-     lib_search_path=`pwd`
-+    inst_prefix_dir=
+--- binutils-2.17.50.0.17/ltmain.sh.orig	2007-06-18 19:29:28.000000000 +0200
++++ binutils-2.17.50.0.17/ltmain.sh	2007-06-21 22:27:40.096178020 +0200
+@@ -4306,6 +4306,7 @@
  
-     avoid_version=no
-     dlfiles=
-@@ -961,6 +962,11 @@
- 	  prev=
- 	  continue
- 	  ;;
-+	inst_prefix)
-+	  inst_prefix_dir="$arg"
-+	  prev=
-+	  continue
-+	  ;;
- 	release)
- 	  release="-$arg"
- 	  prev=
-@@ -1169,6 +1175,11 @@
- 	continue
- 	;;
- 
-+      -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
-       -L[A-Z][A-Z]*:*)
-@@ -2135,6 +2146,14 @@
- 		add="$dir/$linklib"
- 	      elif test "$hardcode_minus_L" = yes; then
- 		add_dir="-L$dir"
-+		# Try looking first in the location we're being installed to.
-+		if test -n "$inst_prefix_dir"; then
-+		  case "$libdir" in
-+		    [\\/]*)
-+		      add_dir="-L$inst_prefix_dir$libdir $add_dir"
-+		      ;;
-+		  esac
-+		fi
- 		add="-l$name"
- 	      elif test "$hardcode_shlibpath_var" = yes; then
- 		add_shlibpath="$dir"
-@@ -2176,6 +2195,7 @@
- 
- 	  if test $linkmode = prog || test "$mode" = relink; then
+ 	  if test "$linkmode" = prog || test "$mode" = relink; then
  	    add_shlibpath=
 +	    add_prefix_dir=
  	    add_dir=
  	    add=
  	    # Finalize command for both is simple: just hardcode it.
-@@ -2193,13 +2213,33 @@
- 	    else
- 	      # We cannot seem to hardcode it, guess we'll fake it.
- 	      add_dir="-L$libdir"
-+	      # Try looking first in the location we're being installed to.
-+	      if test -n "$inst_prefix_dir"; then
-+		case "$libdir" in
-+		  [\\/]*)
-+		    add_dir="-L$inst_prefix_dir$libdir $add_dir"
-+		    ;;
-+		esac
-+	      fi
+@@ -4342,10 +4343,22 @@
  	      add="-l$name"
  	    fi
  
@@ -80,7 +22,7 @@
 +
 +	    # add_prefix_dir must be appended instead, otherwise it can
 +	    # possibly be overrided by any hardcoded -L/... path in deplibs
- 	    if test $linkmode = prog; then
+ 	    if test "$linkmode" = prog; then
 +	      test -n "$add_prefix_dir" && finalize_deplibs="$finalize_deplibs $add_prefix_dir"
  	      test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs"
  	      test -n "$add" && finalize_deplibs="$add $finalize_deplibs"
@@ -89,40 +31,3 @@
  	      test -n "$add_dir" && deplibs="$add_dir $deplibs"
  	      test -n "$add" && deplibs="$add $deplibs"
  	    fi
-@@ -4312,7 +4352,7 @@
-       for tag in $taglist; do
-         tagopts="$tagopts --tag $tag"
-       done
--      relink_command="(cd `pwd`; $SHELL $0$tagopts --mode=relink $libtool_args)"
-+      relink_command="(cd `pwd`; $SHELL $0$tagopts --mode=relink $libtool_args @inst_prefix_dir@)"
-       relink_command=`$echo "X$relink_command" | $Xsed -e "$sed_quote_subst"`
- 
-       # Only create the output if not a dry run.
-@@ -4613,6 +4653,27 @@
- 	dir="$dir$objdir"
- 
- 	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.
-+	  # At present, this check doesn't affect windows .dll's that
-+	  # are installed into $libdir/../bin (currently, that works fine)
-+	  # but it's something to keep an eye on.
-+	  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"
- 	  if $run eval "$relink_command"; then :
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/SOURCES/binutils-libtool-relink.patch?r1=1.1&r2=1.2&f=u



More information about the pld-cvs-commit mailing list