This is the mail archive of the
automake@gnu.org
mailing list for the automake project.
Re: Why do I need both AC_INIT and AM_INIT_AUTOMAKE???
- From: Alexandre Duret-Lutz <duret_g at lrde dot epita dot fr>
- To: Bill Moseley <moseley at hank dot org>
- Cc: automake <automake at gnu dot org>
- Date: Thu, 10 Apr 2003 21:17:33 +0200
- Subject: Re: Why do I need both AC_INIT and AM_INIT_AUTOMAKE???
- References: <Pine.LNX.4.10.10304080547320.30456-100000@mardy.hank.org>
>>> "Bill" == Bill Moseley <moseley at hank dot org> writes:
[...]
Bill> How do you use a shell variable in AC_INIT?
Bill> The docs for AC_INIT say:
Bill> It is preferable that the arguments of `AC_INIT' be static, i.e.,
Bill> there should not be any shell computation, but they can be
Bill> computed by M4.
Bill> And indeed:
Bill> configure.in:5: warning: AC_INIT: not a literal: $VERSION
Consider m4 macros. Static is just a way to say `known at compile
time' (i.e. when Autoconf runs).
m4_define([MAJOR], 1)
m4_define([MINOR], 2)
AC_INIT([foo], [MAJOR.MINOR], [bugs at go dot here])
AM_INIT_AUTOMAKE
(AM_INIT_AUTOMAKE already defines the VERSION variable you don't
need to do it.)
--
Alexandre Duret-Lutz