bug-gnulib
[Top][All Lists]
Advanced

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

conditional dependencies between modules


From: Bruno Haible
Subject: conditional dependencies between modules
Date: Tue, 26 Apr 2011 02:27:52 +0200
User-agent: KMail/1.9.9

Here's an experimental patch that allow conditional dependencies between
modules.

I've tested it on a patch like this one:

--- modules/strtoumax.orig      Tue Apr 26 02:18:36 2011
+++ modules/strtoumax   Tue Apr 26 01:11:38 2011
@@ -8,7 +8,7 @@
 
 Depends-on:
 strtoimax
-strtoull
+strtoull   [test $ac_cv_func_strtoumax = no && test 
$ac_cv_type_unsigned_long_long_int = yes]
 inttypes
 stdint
 

As you can see, the syntax is a bracketed shell expression that is executed
after the module's configure.ac code has run. It has to fit in one line -
no line breaks here please.

Conditional dependencies are enabled by the option --conditional-dependencies.
(If this option is not given, the condition is parsed but ignored.)
It is
  - supposed to work with --create-testdir (tested),
  - supposed to work with --import (not tested),
  - not working with --with-tests (yields an error message).

If you get an error like
  gllib/Makefile.am:137: GL_GENERATE_STDDEF_H does not appear in AM_CONDITIONAL
it is a symptom of a bug of AM_CONDITIONAL in Automake. To work around it,
make the module 'stddef' unconditional by providing it on the command line.

Please test it!

Bruno
-- 
In memoriam Nikolay Gikalo <http://en.wikipedia.org/wiki/Nikolay_Gikalo>

Attachment: conditional-dependencies.diff
Description: Text Data


reply via email to

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