autoconf
[Top][All Lists]
Advanced

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

Re: how to prefix definitions in config.h


From: Paul Eggert
Subject: Re: how to prefix definitions in config.h
Date: Sat, 16 Mar 2002 22:17:04 -0800 (PST)

> From: Akim Demaille <address@hidden>
> Date: 13 Mar 2002 11:23:10 +0100
> 
> My question is merely one of interface.
> 
> Currently
> 
> AC_INIT
> AC_CONFIG_HEADERS(config.h)
> AC_CONFIG_COMMANDS(config.h, [echo Hello, world])
> AC_OUTPUT
> 
> is wrong (grr, it is not caught, I don't know why, but autoconf is
> supposed to die on this).
> 
> My question is should we make this the normal way to hook a command,
> or should we keep this invalid, and introduce
> 
> AC_INIT
> AC_CONFIG_HEADERS(config.h)
> AC_CONFIG_HOOKS(config.h, [echo Hello, world])
> AC_OUTPUT
> 
> or something like that?


Sorry, I don't understand the question.  I went back and read the
thread, and I still don't understand the question.

I did understand Russ Allbery's point.  He wrote that if you need a
config.h variant, then it should be easy enough to create the variant
with a makefile rule that looks something like this:

my_config.h: config.h
        sed 's/#define /#define MY_/; s/#undef /#undef MY_/' <config.h >$@

and once you do that, you don't nee Autoconf to generate my_config.h.

Guido Draheim's rejoinder
<http://mail.gnu.org/pipermail/autoconf/2002-February/012583.html>
doesn't make sense to me.  He seems to be arguing that the makefile
rule is too complicated.  I dunno; it looks pretty simple to me.
Maybe I'm missing something.



reply via email to

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