Git-Url: 
http://git.frugalware.org/gitweb/gitweb.cgi?p=bmf.git;a=commitdiff;h=60647be90468fcb76c37a010dcf6cd8c1fbad7bd

commit 60647be90468fcb76c37a010dcf6cd8c1fbad7bd
Author: crazy <[email protected]>
Date:   Thu Dec 24 23:51:03 2015 +0100

util.sh
* added __as_needed_libtool_hack() function
* and make use of it in Fconf

diff --git a/source/include/util.sh b/source/include/util.sh
index b4f2470..1380055 100644
--- a/source/include/util.sh
+++ b/source/include/util.sh
@@ -1021,6 +1021,15 @@ Fbuildsystem_java_ant () {
;;
esac
}
+__as_needed_libtool_hack() {
+       if [ ! "`check_option NOASNEEDED`" ]; then
+               if [ -e $(pwd)/libtool ]; then
+                       Fmessage "Patching libtool for as-needed...."
+                       ## eg: -shared -> -Wl,--as-needed -shared
+                       sed -i -e 's/ -shared / -Wl,--as-needed\0/g' libtool || 
Fdie
+               fi
+       fi
+}

###
# * Fconf(): A wrapper to ./configure. It will try to run ./configure,
@@ -1048,6 +1057,9 @@ Fconf() {
elif Fbuildsystem_ruby_setup 'probe'; then
Fbuildsystem_ruby_setup 'configure' "$@" || Fdie
fi
+
+       __as_needed_libtool_hack
+
}

###
_______________________________________________
Frugalware-git mailing list
[email protected]
http://frugalware.org/mailman/listinfo/frugalware-git

Reply via email to