Skip to content
Latchkey

automake: Usage, Options & Common CI Errors

automake turns a high-level Makefile.am into a portable Makefile.in.

automake generates the Makefile.in that configure expands into a Makefile. The CI pitfalls are missing auxiliary files (NEWS, README) in default GNU strictness and forgetting --add-missing.

What it does

automake reads Makefile.am files and produces Makefile.in templates that follow GNU conventions (install targets, distcheck, dependency tracking). It is part of autoreconf’s chain and depends on aclocal-collected macros.

Common usage

Terminal
automake --add-missing --copy
autoreconf -fi                     # runs automake for you
automake --foreign --add-missing   # relax GNU file requirements
aclocal && automake && autoconf
./configure && make

Options

FlagWhat it does
--add-missingAdd required helper scripts (install-sh, etc.)
--copyCopy helpers instead of symlinking
--foreignRelax GNU strictness (no NEWS/README)
--force-missingOverwrite existing helper files
-Wall -WerrorTreat automake warnings as errors

Common errors in CI

"required file ‘./NEWS’ not found" (also README, AUTHORS, ChangeLog) appears under default GNU strictness - either add the files or set AM_INIT_AUTOMAKE([foreign]) / run with --foreign. "Makefile.am: required file ‘./install-sh’ not found" - run automake --add-missing (autoreconf -fi does this). Version skew between the committed Makefile.in and the installed automake causes "aclocal-1.NN: not found"; regenerate from source with autoreconf -fi in CI.

Related guides

Run this faster and cheaper on Latchkey managed runners. Start free →