Re: Removing duplicate occurences from dependency_libs



On 20 May 2001 15:46:39 +0200, Martin Baulig wrote:
[....]
> If you have a "complicated" dependency setup, this will slow down
linking
> in a very extreme way (it is more than 5 times slower for me) because I get
> libraries like -lm or -ldl listed over 30 times in the dependency_libs.

Hi,
	I thought I'd mention that it seems
to me that the speed hit is in the
construction of the list of
dependencies, not during actual
linking. If you put "set -x" at the
top of libtool and link something
like evolution-mail, you'll see the
list of dependencies grow larger and
larger till it takes up almost the
complete screen.
	Fortunately, since we have
gnome-config et al, we don't need
libtool's smart 'dependency libs'
included in the .la file. The
attached patch to ltmain.sh turns
this off and makes a huge speed
difference for me:
	Before: > 8 minutes to link
evolution-mail
	 After: ~ 4 seconds
	Obviously this is not the "right"
solution, but if you're getting
frustrated at Evolution taking 5
hours to compile, this may help :-)


--
Peter Williams     peter newton cx / peterw ximian com

"Why should I have to change my name? He's the one who 
sucks!"                              -- Michael Bolton
--- /usr/share/libtool/ltmain.sh	Sat May 12 19:29:42 2001
+++ ./ltmain.sh	Wed May 23 20:02:10 2001
@@ -1530,6 +1530,8 @@
 	    convenience="$convenience $ladir/$objdir/$old_library"
 	    old_convenience="$old_convenience $ladir/$objdir/$old_library"
 	    tmp_libs=
+	    # PKGW 
+	    dependency_libs=
 	    for deplib in $dependency_libs; do
 	      deplibs="$deplib $deplibs"
 	      case "$tmp_libs " in
@@ -1645,6 +1647,8 @@
 	  fi
 
 	  tmp_libs=
+	  #PKGW
+	  dependency_libs=
 	  for deplib in $dependency_libs; do
 	    case $deplib in
 	    -L*) newlib_search_path="$newlib_search_path "`$echo "X$deplib" | $Xsed -e 's/^-L//'`;; ### testsuite: skip nested quoting test


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]