Next: , Previous: , Up: Invoking gnulib-tool   [Contents][Index]

3.8 Modifying the build rules of a Gnulib import directory

In some cases, you may want to set additional compiler options for use within the Gnulib import directory. For example, the ‘relocatable’ module operates better if you define the C macros ENABLE_COSTLY_RELOCATABLE and INSTALLDIR during its compilation.

There are two ways to do so: Use of the gnulib-tool option --makefile-name, and a kitchen-sink module.

With the gnulib-tool option --makefile-name, you are telling gnulib-tool to generate an includable portion, rather than a self-contained For example, when you use --makefile-name=Makefile.gnulib, gnulib-tool will generate Makefile.gnulib, and you will provide a hand-written that includes Makefile.gnulib through a line such as

include Makefile.gnulib

Before this include, you need to initialize this set of variables:

AUTOMAKE_OPTIONS should be initialized as described in Changing Automake’s Behavior in GNU Automake. The other variables can be initialized to empty. However, you will most likely want to initialize some of them with non-empty values, in order to achieve the desired customization.

The other approach, the kitchen-sink module, is more advanced. See chapter Extending Gnulib.