Re: How to specify /var/lib in autoconf?

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

 



David Bruce <davidstuartbruce <at> gmail.com> writes:

> > If you want to refer to the path in C code as a macro "LOCALSTATEDIR",
> > you have in Makefile.am:
> >
> >  AM_CPPFLAGS = -DLOCALSTATEDIR=\"$(pkglocalstatedir)\"
> 
> But is pkglocalstatedir predefined, like pkgdatadir, pkglibdir, and
> pkgincludedir? It doesn't seem like it.

Not yet.  But if you file a bug report to automake, I'm sure Ralf would 
consider adding it.

> Am I first supposed to do something like:
> pkglocalstatedir = $(localstatedir)/@PACKAGE@

Until automake provides it, yes.  Or $(localstatedir)/$(PACKAGE), since 
automake already provides $(PACKAGE) as the preferred spelling of @PACKAGE@ 
within Makefile.am.

> Regarding the GNU Coding Standards vs. FHS discrepancy in where the
> files wind up getting installed, am I safe to assume that as the
> "upstream guy" I can just follow the Autotools defaults? The distro
> packagers ought to know to use "./configure --localstatedir=/var" to
> get these files into the FHS-approved place, right?

Yep, you got it in one!  Distro packages could also use a config.site policy to 
get it right without having to add --localstatedir to every ./configure run, 
but the net result is the same.

-- 
Eric Blake





_______________________________________________
Autoconf mailing list
Autoconf@xxxxxxx
http://lists.gnu.org/mailman/listinfo/autoconf

[Index of Archives]     [GCC Help]     [Kernel Discussion]     [RPM Discussion]     [Red Hat Development]     [Yosemite News]     [Linux USB]     [Samba]

  Powered by Linux