automake
[Top][All Lists]
Advanced

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

Re: What is it with the dependency on config.status


From: Nick Bowler
Subject: Re: What is it with the dependency on config.status
Date: Mon, 9 Jan 2012 11:35:33 -0500
User-agent: Mutt/1.5.21 (2010-09-15)

Hello Jan,

On 2012-01-09 17:23 +0100, Jan Engelhardt wrote:
> On Sunday 2012-01-01 10:24, Stefano Lattarini wrote:
> >On 12/31/2011 12:29 AM, Jan Engelhardt wrote:
> >> 
> >> I have seen user-induced lines in Makefile.am like these in a handful 
> >> of packages:
[...]
> For example libntlm [http://www.nongnu.org/libntlm/releases/] in 
> gl/Makefile.am:
> 
>       else
>       byteswap.h: $(top_builddir)/config.status
>               rm -f $@
>       endif

This instance (presumably) comes from Gnulib's byteswap module.  This
header is generated at make time based on stuff determined by configure:
so it needs to be regenerated if the package configuration changes.  Or,
as in the part you quoted, it may need to be deleted if the configuration
changes such that the header is no longer necessary.  Since config.status
is updated whenever configure is run, this dependency ensures that the
headers will be updated if the configuration is changed.  This approach
is used throughout Gnulib.

Unfortunately, this dependency is a bit broader than actually required,
because it means the headers will be updated whenever configure is re-run
for any reason: even if the configuration has not changed (and the
updated header is therefore unchanged from the previously generated
one).  This tends to cause object files in Gnulib-using packages to be
needlessly rebuilt whenever you re-run configure, which is a bit
unfortunate.  I'm not really sure why Gnulib doesn't use autoconf's
AC_CONFIG_FILES mechanism to generate these headers.

Cheers,
-- 
Nick Bowler, Elliptic Technologies (http://www.elliptictech.com/)




reply via email to

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