Subversion Repositories pub

Compare Revisions

Ignore whitespace Rev 46 → Rev 47

/nautilus-follow-symlink/trunk/nautilus/kludges/README
0,0 → 1,13
libtool-honor-as-needed.patch contains a patch against ltmain.sh (generated
on bootstrap to make use of libtool), so that it doesn't reorder
"-Wl,--as-needed", a linker flag that removes unnecessary dependencies.
It only applies to libraries listed after it, but libtool always pushes
it after the libs in the command line, so it does nothing, normally.
 
References:
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=347650
"Debian bug #347650: libtool: Incorrect argument reordering"
[Source of patch]
http://sigquit.wordpress.com/2011/02/16/why-asneeded-doesnt-work-as-expected-for-your-libraries-on-your-autotools-project/
"Why --as-needed doesn't work as expected for your libraries on your autotools project"
 
/nautilus-follow-symlink/trunk/nautilus/kludges/libtool-honor-as-needed.patch
0,0 → 1,30
--- ltmain.sh.orig 2012-08-14 11:36:48.211924221 +0200
+++ ltmain.sh 2012-08-14 11:42:48.663918234 +0200
@@ -5800,6 +5800,11 @@
arg=$func_stripname_result
;;
+ -Wl,--as-needed|-Wl,--no-as-needed)
+ deplibs="$deplibs $arg"
+ continue
+ ;;
+
-Wl,*)
func_stripname '-Wl,' '' "$arg"
args=$func_stripname_result
@@ -6163,6 +6168,15 @@
lib=
found=no
case $deplib in
+ -Wl,--as-needed|-Wl,--no-as-needed)
+ if test "$linkmode,$pass" = "prog,link"; then
+ compile_deplibs="$deplib $compile_deplibs"
+ finalize_deplibs="$deplib $finalize_deplibs"
+ else
+ deplibs="$deplib $deplibs"
+ fi
+ continue
+ ;;
-mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \
|-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*)
if test "$linkmode,$pass" = "prog,link"; then