2023-03-09 14:35:13 +00:00
|
|
|
From 7f2b8a1ab4fa1475eeeddfb84eb5b92594bfce43 Mon Sep 17 00:00:00 2001
|
|
|
|
From: Eneas U de Queiroz <cotequeiroz@gmail.com>
|
|
|
|
Date: Tue, 20 Jul 2021 16:54:12 -0300
|
|
|
|
Subject: openwrt: strip unsave directories from relink command
|
|
|
|
|
|
|
|
strip unsave directories from relink command, nuke every -L that looks
|
|
|
|
like /usr/lib or /lib
|
|
|
|
|
|
|
|
This was originally commited to openwrt by Jo-Philipp Wich
|
|
|
|
<jow@openwrt.org>.
|
|
|
|
|
|
|
|
Signed-off-by: Eneas U de Queiroz <cotequeiroz@gmail.com>
|
|
|
|
|
2021-09-13 21:08:55 +00:00
|
|
|
--- a/build-aux/ltmain.in
|
|
|
|
+++ b/build-aux/ltmain.in
|
2022-03-31 23:13:17 +00:00
|
|
|
@@ -2400,6 +2400,9 @@ func_mode_install ()
|
2010-12-20 19:43:57 +00:00
|
|
|
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:]]*%%"`
|
|
|
|
+
|
2021-09-13 21:08:55 +00:00
|
|
|
func_warning "relinking '$file'"
|
2010-12-20 19:43:57 +00:00
|
|
|
func_show_eval "$relink_command" \
|
2021-09-13 21:08:55 +00:00
|
|
|
'func_fatal_error "error: relink '\''$file'\'' with the above command before installing it"'
|