[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: $(datadir) and @datadir@
From: |
Ralf Wildenhues |
Subject: |
Re: $(datadir) and @datadir@ |
Date: |
Tue, 13 Feb 2007 13:26:08 +0100 |
User-agent: |
Mutt/1.5.13 (2007-02-12) |
* Christian Parpart wrote on Tue, Feb 13, 2007 at 12:45:04PM CET:
> On Thursday 08 February 2007 20:47:53 Albert Chin wrote:
> >
> > If you use $(datadir), the user can override it at build time (e.g.
> > make datadir='<path>'). Not so with @datadir@ where the @datadir@
> > string is replaced in-place.
>
> there's also a third way: ${datadir} which I can't understand the difference
> of - is there?
As far as `make' is concerned, $(foo) and ${foo} are equivalent.
Sometimes it is useful however to use a notation that is understood by
all of: make, shell, perl (and others). Then ${foo} has advantages.
Remember that AC_CONFIG_FILES() can list arbitrary files as output, from
an Autoconf POV all it does is substitute some @variables@ in FILE.in
with values. (It's automake that looks for FILE.am for each such FILE
and then takes them as input to create FILE.in.)
Cheers,
Ralf