[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: configmake module and automake 1.9.6
From: |
Eric Blake |
Subject: |
Re: configmake module and automake 1.9.6 |
Date: |
Tue, 14 Dec 2010 14:14:11 -0700 |
User-agent: |
Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.13) Gecko/20101209 Fedora/3.1.7-0.35.b3pre.fc14 Lightning/1.0b3pre Mnenhy/0.8.3 Thunderbird/3.1.7 |
On 12/14/2010 02:10 PM, Bruno Haible wrote:
> Eric Blake wrote:
>> I just ran into an issue where libvirt failed to compile when autotooled
>> with automake 1.9.6, because automake failed to define $(localedir) and
>> therefore gnulib's configmake module did not define LOCALEDIR. Any
>> suggestions on how to make gnulib guarantee $(localedir) will be defined
>> even when using older automake, such as an extra snippet of code to
>> include in Makefile.am, and which will not interfere when using newer
>> automake?
>
> In Makefile.am add:
>
> localedir = @localedir@
>
> In configure.ac add:
>
> dnl Installation directories.
> dnl Remove this when you can assume autoconf >= 2.60.
> AC_SUBST([localedir], ['${datadir}/locale'])
But the Makefile.am in question is generated by gnulib. Adding it to
the top level won't affect the generation of configmake.h.
I'm going for a different approach, I'm in the middle of testing this
(well, expanding it further for fallbacks for all of the variables,
including LOCALEDIR):
diff --git i/ChangeLog w/ChangeLog
index c9c467c..bf7f17b 100644
--- i/ChangeLog
+++ w/ChangeLog
@@ -1,3 +1,9 @@
+2010-12-14 Eric Blake <address@hidden>
+
+ configmake: support more values with older automake
+ * modules/configmake (Makefile.am): Provide fallbacks for older
+ automake.
+
2010-12-13 Eric Blake <address@hidden>
cloexec, fcntl: relax license
diff --git i/modules/configmake w/modules/configmake
index d826c13..a19f3da 100644
--- i/modules/configmake
+++ w/modules/configmake
@@ -25,6 +25,7 @@ Makefile.am:
# Listed in the same order as the GNU makefile conventions.
# The Automake-defined pkg* macros are appended, in the order
# listed in the Automake 1.10a+ documentation.
+# Support newer definitions even when using older automake 1.9.6
configmake.h: Makefile
$(AM_V_GEN)rm -f address@hidden && \
{ echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
@@ -35,6 +36,9 @@ configmake.h: Makefile
echo '#define LIBEXECDIR "$(libexecdir)"'; \
echo '#define DATAROOTDIR "$(datarootdir)"'; \
echo '#define DATADIR "$(datadir)"'; \
+ echo '#ifndef DATAROOTDIR'; \
+ echo '# define DATAROOTDIR DATADIR'; \
+ echo '#endif; \
echo '#define SYSCONFDIR "$(sysconfdir)"'; \
echo '#define SHAREDSTATEDIR "$(sharedstatedir)"'; \
echo '#define LOCALSTATEDIR "$(localstatedir)"'; \
--
Eric Blake address@hidden +1-801-349-2682
Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature
- configmake module and automake 1.9.6, Eric Blake, 2010/12/14
- Re: configmake module and automake 1.9.6, Bruno Haible, 2010/12/14
- Re: configmake module and automake 1.9.6,
Eric Blake <=
- Re: configmake module and automake 1.9.6, Ralf Wildenhues, 2010/12/14
- Re: configmake module and automake 1.9.6, Bruno Haible, 2010/12/14
- Re: configmake module and automake 1.9.6, Eric Blake, 2010/12/14
- Re: configmake module and automake 1.9.6, Eric Blake, 2010/12/14
- Diagnose invalid primary/directory combinations (was: Re: configmake module and automake 1.9.6), Stefano Lattarini, 2010/12/15