Hello Sam, > >> So: how do I use aclocal.m4 with multiple subpackage configure.in?
if my yesterday's mail haven't convinced you, here are a few hints: Normally, aclocal finds all necessary macros and concatenates them to form aclocal.m4. But if the macros live in subdirectory m4/ (and aclocal was called with option "-I m4"), aclocal doesn't copy the whole file, it just creates a line looking like: m4_include([m4/mymacro.m4]) So you could find all macro files which are needed, copy them to one m4 directory, and aclocal.m4 would contain only such inlcude lines, subdir/aclocal.m4 would contain m4_include([../m4/mymacro.m4]) But how would you find the collection of all necessary m4 files? Well, one possibility is to take all m4 files: mkdir m4/ cp /usr/share/aclocal/*.m4 /usr/share/aclocal-1.9/*.m4 m4/ then run aclocal -I m4, aclocal -I ../m4, etc., in all subprojects. And then remove unused m4 files, ie. those which are not referenced from any aclocal.m4. In the cvs version of Automake, aclocal has option --include, which does this: all needed m4 files are copied to subdirectory m4/, and aclocal.m4 contains only m4_include directives. So you would just do mkdir m4/ aclocal -I m4 (cd sub1; aclocal -I ../m4) (cd sub2; aclocal -I ../m4) ... To install the CVS version of automake, you have to install CVS version of Autoconf first. Or you can just take aclocal.in from CVS and incorporate this change into automake-1.9.6/aclocal.in . CVS log should help you to extract the exact patch that you need. Good luck, Stepan