[Top][All Lists]

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

Re: automake -vs- huge projects

From: Alexandre Duret-Lutz
Subject: Re: automake -vs- huge projects
Date: Wed, 17 Dec 2003 00:15:21 +0100
User-agent: Gnus/5.1003 (Gnus v5.10.3) Emacs/21.3 (gnu/linux)

>>> "Thomas" == Thomas Fitzsimmons <address@hidden> writes:

 Thomas> One specifc problem I noticed is that automake is
 Thomas> generating three explicit rules for each target.  For
 Thomas> example, for one .java file, these rules are generated:
 Thomas> I would only expect rules for .lo files, since we are
 Thomas> generating libtool libraries.  Getting rid of the other
 Thomas> targets would cut out *a lot* of the bulk.


I think we can construct cases that will break if any of the .o
or .lo rules are left out, for instance

  bin_PROGRAMS = foo
  foo_SOURCES = a.c b.c
  libbar_la_SOURCES = 1.c 2.c
  libbar_la_LIBADD = @MOREBAR@

now think about @MOREFOO@ being substituted into 1.o or 2.o, and
@MOREBAR@ being replaced by or  However it seems
fair to require that the above snippet be rewritten as

  bin_PROGRAMS = foo
  foo_SOURCES = a.c b.c
  EXTRA_foo_SOURCES = 1.c 2.c
  libbar_la_SOURCES = 1.c 2.c
  libbar_la_LDADD =  @MOREBAR@
  EXTRA_libbar_la_SOURCES = a.c b.c

like the manual says (oh well, I hope it says so).  And in this
second example it is clear which rules Automake needs to output.

Furthermore, generally it does not work to compile both the .o
and .lo objects of a source file (in the last example Automake
is expected to warn that these files are being built both with
and without Libtool), so it sounds safe to remove the rules
which are not used.
Alexandre Duret-Lutz

reply via email to

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