automake-patches
[Top][All Lists]
Advanced

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

Re: Faster install for libtool outputs.


From: Ralf Wildenhues
Subject: Re: Faster install for libtool outputs.
Date: Sat, 20 Sep 2008 13:04:16 +0200
User-agent: Mutt/1.5.18 (2008-05-17)

* Ralf Wildenhues wrote on Sun, Sep 14, 2008 at 03:23:45PM CEST:
> * unlike lib_LTLIBRARIES, nobase_lib_LTLIBRARIES aren't consistently
>   installed before bin_PROGRAMS.  :-/

Yes, this fix is more of an ugly ugly hack, just like the hack done for
lib_LTLIBRARIES.  I figured two consistent hacks aren't worse than one,
though.  And fixing the install ordering issue right (in the presence of
circular dependencies?  conditionals and @substitutions@ in LIBADD?  can
we ignore inter-makefile LIBADDs?) is not something I want to start
getting a headache from right now.

Cheers,
Ralf

   Install nobase_lib_LTLIBRARIES before bin_PROGRAMS.

   * automake.in (generate_makefile): If nobase_lib_LTLIBRARIES are
   used, add an ugly hack to install them before bin_PROGRAMS, just
   like done with lib_LTLIBRARIES.
   * tests/ltorder.test: Add program, to expose this.

diff --git a/automake.in b/automake.in
index 54f6865..796f17d 100755
--- a/automake.in
+++ b/automake.in
@@ -7680,6 +7680,10 @@ sub generate_makefile ($$)
     {
       $output_rules .= "install-binPROGRAMS: install-libLTLIBRARIES\n\n";
     }
+  if (var ('nobase_lib_LTLIBRARIES') && var ('bin_PROGRAMS'))
+    {
+      $output_rules .= "install-binPROGRAMS: 
install-nobase_libLTLIBRARIES\n\n";
+    }
 
   handle_install;
   handle_clean ($makefile);
diff --git a/tests/ltorder.test b/tests/ltorder.test
index 9994008..1d1e65e 100755
--- a/tests/ltorder.test
+++ b/tests/ltorder.test
@@ -33,6 +33,8 @@ sub_liba2_la_LIBADD = liba1.la
 sub_liba3_la_LIBADD = sub/liba2.la
 liba4_la_LIBADD = sub/liba3.la
 liba5_la_LIBADD = liba4.la
+bin_PROGRAMS = p
+p_LDADD = liba5.la
 END
 
 mkdir sub
@@ -41,6 +43,7 @@ echo 'extern int a1 (); int a2 () { return a1 (); }' 
>sub/liba2.c
 echo 'extern int a2 (); int a3 () { return a2 (); }' >sub/liba3.c
 echo 'extern int a3 (); int a4 () { return a3 (); }' >liba4.c
 echo 'extern int a4 (); int a5 () { return a4 (); }' >liba5.c
+echo 'extern int a5 (); int main () { return a5 (); }' >p.c
 
 libtoolize
 $ACLOCAL




reply via email to

[Prev in Thread] Current Thread [Next in Thread]