Touch the generated autotools files so the bundled Ragel build does not re-run automake
Symptom#
The cibuildwheel Linux build (Ragel 6.10 built from the CPM tarball for Vectorscan) fails with automake-1.15: command not found and Error 127 under ragel-build/ragel.
Cause#
After CPM extracts the tarball, Makefile.am is newer than the generated Makefile.in, so make tries to re-run automake, which the container lacks. Skipping the doc directory with make -C ragel is not enough, because the same failure then hits ragel/.
Fix#
From CMake, touch the generated autotools files (aclocal.m4, configure, every Makefile.in, config.h.in) before running configure. Keep make -C ragel and make -C ragel install. To reproduce locally, copy the tarball, touch the .am files so they are newer, then build. Check the CMake steps with cmake -P.
Evidence#
Reported in an observed note from the dftracer-utils wheel build work; the note says this fix worked.
Also found by searching
- automake-1.15: command not found Error 127 ragel-build/ragel
- cibuildwheel Linux wheel build fails building bundled Ragel for Vectorscan
- how do I stop make from re-running automake on a CPM-extracted tarball
- Makefile.am newer than Makefile.in after extracting a tarball in a container without automake