Hi Tim, * Tim Bocek wrote on Fri, Oct 24, 2008 at 07:20:18PM CEST: > I kind of an autotools novice and have a problem with using the include > directive in make and automake. I need to generate an include file at make > time, so this file is not available when I run automake.
Do you require GNU make for building your package? > Is there any way to tell automake to defer including the file to when make > is run? With GNU make, I see a couple of ways to hide the include from automake: 1) Create a GNUmakefile in the same build directory with contents include Makefile include generated-file 2) prepend a substitution: put AC_SUBST([myinclude], [include]) in configure.ac, and use @include@ generated-file Even for portable make, I see a way, but it uses a currently undocumented feature of Automake (thus may break in future versions): For dependency tracking, the macro AM_MAKE_INCLUDE finds out how the make implementation allows file inclusion. It sets @am__include@ which you can use then as portable include. Cheers, Ralf