File: libtool-cross.patch

package info (click to toggle)
libtododb 0.11-3
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 1,516 kB
  • sloc: sh: 8,767; ansic: 466; xml: 262; makefile: 50
file content (58 lines) | stat: -rw-r--r-- 2,091 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
--- libtool	2005-04-10 23:08:25.096937976 +0200
+++ libtool.orig	2005-04-10 23:08:09.148362528 +0200
@@ -2489,8 +2489,14 @@
 	    absdir="$abs_ladir"
 	    libdir="$abs_ladir"
 	  else
-	    dir="$libdir"
-	    absdir="$libdir"
+            # Adding 'libdir' from the .la file to our library search paths
+            # breaks crosscompilation horribly.  We cheat here and don't add
+            # it, instead adding the path where we found the .la.  -CL
+	    dir="$abs_ladir"
+	    absdir="$abs_ladir"
+	    libdir="$abs_ladir"
+	    #dir="$libdir"
+	    #absdir="$libdir"	  
 	  fi
 	else
 	  dir="$ladir/$objdir"
@@ -2957,15 +2963,16 @@
 		esac
 		if grep "^installed=no" $deplib > /dev/null; then
 		  path="$absdir/$objdir"
-		else
-		  eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib`
-		  if test -z "$libdir"; then
-		    $echo "$modename: \`$deplib' is not a valid libtool archive" 1>&2
-		    exit $EXIT_FAILURE
-		  fi
-		  if test "$absdir" != "$libdir"; then
-		    $echo "$modename: warning: \`$deplib' seems to be moved" 1>&2
-		  fi
+# 		This interferes with crosscompilation. -CL
+#		else		
+#		  eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib`
+#		  if test -z "$libdir"; then
+#		    $echo "$modename: \`$deplib' is not a valid libtool archive" 1>&2
+#		    exit $EXIT_FAILURE
+#		  fi
+#		  if test "$absdir" != "$libdir"; then
+#		    $echo "$modename: warning: \`$deplib' seems to be moved" 1>&2
+#		  fi
 		  path="$absdir"
 		fi
 		depdepl=
@@ -5512,7 +5519,11 @@
 	    # Replace all uninstalled libtool libraries with the installed ones
 	    newdependency_libs=
 	    for deplib in $dependency_libs; do
-	      case $deplib in
+	    # Replacing uninstalled with installed can easily break crosscompilation,
+            # since the installed path is generally the wrong architecture.  -CL
+              newdependency_libs="$newdependency_libs $deplib"
+              continue	      
+              case $deplib in
 	      *.la)
 		name=`$echo "X$deplib" | $Xsed -e 's%^.*/%%'`
 		eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib`