On Mon, 19 Nov 2012, Eric Blake wrote:

You can reduce the pain by using variables:

more = more
prog_SOURCES += ${more}/file3.c ${more}/file4.c

so that a rename now only has to touch the 'more =' line, rather than
every use.

The most serious problem is this incantation for 'prog' output to subdirectory 'foo/bar':

foo_bar_prog_SOURCES += foo/bar/file3.c foo/bar/file4.c

Note that the make variable name needs to include a representation of the path components.

A good paradigm for non-recursive make is to put Automake include fragments into each directory which support the files in that directory. The top Automake.am then includes these fragments. It would be useful if there was a syntax whereby the necessary subdirectory paths could be automatically inserted into Makefile variables and file paths based on the location of the Automake include file.

Since Makefile.in is produced by Perl, it should be possible to support this path simplification while still building a working makefile which emulates a heirarchical build style.

Bob
--
Bob Friesenhahn
bfrie...@simple.dallas.tx.us, http://www.simplesystems.org/users/bfriesen/
GraphicsMagick Maintainer,    http://www.GraphicsMagick.org/

Reply via email to