summaryrefslogtreecommitdiff
path: root/tools/libtool
diff options
context:
space:
mode:
authorJo-Philipp Wich <jow@openwrt.org>2010-12-20 19:43:57 +0000
committerJo-Philipp Wich <jow@openwrt.org>2010-12-20 19:43:57 +0000
commit22da5f54e9db8e3ba85c0ccbbb115a96bb12a701 (patch)
tree2495c466d31ec0995adb00f8f17817fc61620a7f /tools/libtool
parent1b37ee06f1dc188411f01db9509c4f1cac11e87c (diff)
downloadmtk-20170518-22da5f54e9db8e3ba85c0ccbbb115a96bb12a701.zip
mtk-20170518-22da5f54e9db8e3ba85c0ccbbb115a96bb12a701.tar.gz
mtk-20170518-22da5f54e9db8e3ba85c0ccbbb115a96bb12a701.tar.bz2
libtool: strip unsave directories from relink command, nuke every -L that looks like /usr/lib or /lib
SVN-Revision: 24741
Diffstat (limited to 'tools/libtool')
-rw-r--r--tools/libtool/patches/120-strip-unsafe-dirs-for-relinking.patch12
1 files changed, 12 insertions, 0 deletions
diff --git a/tools/libtool/patches/120-strip-unsafe-dirs-for-relinking.patch b/tools/libtool/patches/120-strip-unsafe-dirs-for-relinking.patch
new file mode 100644
index 0000000..564d885
--- /dev/null
+++ b/tools/libtool/patches/120-strip-unsafe-dirs-for-relinking.patch
@@ -0,0 +1,12 @@
+--- a/libltdl/config/ltmain.m4sh
++++ b/libltdl/config/ltmain.m4sh
+@@ -2183,6 +2183,9 @@ func_mode_install ()
+ relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%%"`
+ fi
+
++ relink_command=`$ECHO "$relink_command" | $SED "s%-L[[:space:]]*/lib[^[:space:]]*%%"`
++ relink_command=`$ECHO "$relink_command" | $SED "s%-L[[:space:]]*/usr/lib[^[:space:]]*%%"`
++
+ func_warning "relinking \`$file'"
+ func_show_eval "$relink_command" \
+ 'func_fatal_error "error: relink \`$file'\'' with the above command before installing it"'