CMake support was introduced as experimental in #1113 (v0.3.0) and promoted to a standard build procedure in #1680 (v0.7.0). Since then, every build system change has had to be implemented, reviewed and tested twice.
That cost keeps coming up in review. From #2008 (comment):
We'd need to test both Autotools and CMake. (This sound a bit like a good reason to start thinking about a deprecation of Autotools?!)
And from #1332#pullrequestreview-6060234395:
What's your opinion on dropping Autotools? I tend to say I'd like to get rid of it, but it's hard to know what ours users actually need.
Also from #1332#pullrequestreview-6060234395:
These old Autotools test programs violate modern best practices heavily...
This issue is meant to answer that open question before any PR is opened.
Proposal
- Announce the deprecation in the changelog and print a notice at the end of
./configure. - Remove the Autotools-based build system once the items in the lists below are resolved.
Autotools features and workflows not yet supported by CMake
- Regenerating the precomputed tables (
make clean-precomp && make precomp). Being addressed in #1791. - Regenerating the test vectors (
make clean-testvectors && make testvectors). - Shared library versioning on exotic platforms.
cmake/SetLibtoolAbiVersion.cmakehandles Linux, FreeBSD, NetBSD, OpenBSD, macOS and Windows. Elsewhere, CMake produces an unversionedlibsecp256k1.so. - The
-devversion suffix for non-release builds (_PKG_VERSION_IS_RELEASE). CMake reports0.8.1where Autotools reports0.8.1-dev. make uninstall.make distandmake distcheck.
Note: Downstream projects that find libsecp256k1 via pkg-config are not affected. The CMake build installs libsecp256k1.pc as well, generated from the same libsecp256k1.pc.in template.
Other prerequisites
- Port CI to CMake.
ci/ci.shdrives all Linux, macOS and MinGW jobs through Autotools. CMake is exercised only in the MSVC and clang-cl jobs and in an install check. - Update the documentation that mentions
./configureflags (README.md,CONTRIBUTING.md,doc/release-process.md).
Is anything missing from these lists?