Skip to content

Migrate Build System from Autotools to CMake #488

@somethingwithproof

Description

@somethingwithproof

Summary

As part of the '2026 Enterprise Ready' roadmap, Spine should transition its build system from legacy Autotools (configure.ac, Makefile.am) to CMake.

Work

Why Migrate?

  1. Modern Tooling: CMake trivially generates compile_commands.json, which is required for modern IDEs (clangd), advanced static analysis (CodeQL, clang-tidy), and secure build tooling.
  2. Speed: CMake, especially when paired with the Ninja backend, evaluates the build graph and parallelizes compilation significantly faster than standard make.
  3. Developer Experience: Autotools (m4 macros) represents significant technical debt and a high barrier to entry for new contributors. CMake is the undisputed industry standard for C/C++ projects.
  4. Testing Integration: CTest provides a structured, modern framework for running tests (including Valgrind) directly from the build system, simplifying our CI pipelines.

Implementation Plan

  1. Write a CMakeLists.txt that mirrors the exact feature detection logic currently in configure.ac (finding libmysqlclient, libnetsnmp, libssl, checking for cap_t, etc.).
  2. Implement install rules and CTest targets for existing tests.
  3. Update GitHub Actions workflows to exclusively use the CMake path (removing the fallback logic).
  4. Run CMake side-by-side with Autotools for a deprecation period, then remove bootstrap, configure.ac, and Makefile.am.

Acceptance Criteria

  • Work items are implemented and validated.
  • Changes preserve behavior unless explicitly intended.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions