Subversion Repositories

?revision_form?Rev ?revision_input??revision_submit??revision_endform?

Rev 116 | Rev 149 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
2 magnus 1
#! /bin/sh /usr/share/dpatch/dpatch-run
41 magnus 2
## 02_smartlink_rpath.dpatch
2 magnus 3
##
4
## All lines beginning with `## DP:' are a description of the patch.
5
## DP: Make smartlink not use -rpath
6
 
7
@DPATCH@
130 holmgren 8
--- a/bin/smartlink
9
+++ b/bin/smartlink
10
@@ -162,9 +162,8 @@ if test x$# != x0 ; then
2 magnus 11
      LDOPTS="$LDOPTS -R$RPATH"
12
    ;;
13
    Linux\ 2.*)
14
-     if test x$LINKING != xno -a "x$RPATH" != x ; then
15
-      LDOPTS="$LDOPTS -Wl,-rpath,$RPATH"
16
-     fi
17
+     LD_LIBRARY_PATH="$RPATH"
18
+     export LD_LIBRARY_PATH
19
    ;;
20
    UnixWare\ 7.*)
21
      if test x$LINKING != xno -a "x$RPATH" != x ; then
130 holmgren 22
--- a/src/smartlink.c
23
+++ b/src/smartlink.c
24
@@ -160,7 +160,7 @@ int main(int argc, char **argv)
2 magnus 25
   full_rpath = rpath;
26
 
27
 #ifdef USE_Wl
28
-  strcat(rpath, "-Wl,-rpath,");
29
+  /* strcat(rpath, "-Wl,-rpath,"); */
30
 #elif defined(USE_Wl_R)
31
   strcat(rpath, "-Wl,-R");
32
 #elif defined(USE_R)
130 holmgren 33
@@ -310,7 +310,7 @@ int main(int argc, char **argv)
2 magnus 34
     }
35
     rpath_in_use |= add_path(rpath, ld_lib_path);
36
   }
37
-
38
+#if 0
39
   if (rpath_in_use) {
40
     /* Delete the terminating ':' */
41
     rpath[strlen(rpath) - 1] = 0;
130 holmgren 42
@@ -357,6 +357,7 @@ int main(int argc, char **argv)
2 magnus 43
 #error Unknown method
44
 #endif
45
   }
46
+#endif
47
 
48
   new_argv[new_argc++] = NULL;
49