[Top][All Lists]

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

Re: [automake] Dependency question with _LDADD

From: Peter Johansson
Subject: Re: [automake] Dependency question with _LDADD
Date: Tue, 07 Oct 2008 11:21:26 -0400
User-agent: Thunderbird (X11/20080723)

Hello Michel,

Michel Briand wrote:
Hi all,

I implemented a new idea for program's version.

In src/bin/

internal_version.c: ${top_srcdir}/PROGRAM_VERSION
        ${top_srcdir}/ $(component) $(VERSION) < $(templ) > $@

training_SOURCES = training.c internal_version.c

The Perl program takes a template as input and filter it to
produce the internal_version.c source file.

Each time the PROGRAM_VERSION file will be changed, the new source file
will be regenerated, then the build system will recompile it, and
relink the program.
The source file will be regenerated only if PROGRAM_VERSION is changed, though. I would add the template file, the perl script `', and `Maskefile' in the list of dependencies.

I don't know what your perl script looks like or what it achieves, but I could imagine you could achieve something similar with a simple sed call. See chapter 4.8.2 in autoconf manual for an example Thereby you could avoid the requirement that users need perl to build your package.

Also, what is the reason you don't want to use config.h?

Comments are welcome.

Best regards,


reply via email to

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