Skip to content

Compatibility with CMake < 3.5 has been removed from CMake #17

@samvv

Description

@samvv

Hi,

I have read your issue on the TypeScript repo. It was inspiring. Just to educate myself I'm trying to replicate your idea in Rust.

CMake code generation fails with:

-- The C compiler identification is GNU 15.1.1
-- The CXX compiler identification is GNU 15.1.1
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
CMake Error at libs/doctest/CMakeLists.txt:1 (cmake_minimum_required):
  Compatibility with CMake < 3.5 has been removed from CMake.

  Update the VERSION argument <min> value.  Or, use the <min>...<max> syntax
  to tell CMake that the project requires at least <min> but has been updated
  to work with policies introduced by <max> or earlier.

  Or, add -DCMAKE_POLICY_VERSION_MINIMUM=3.5 to try configuring anyway.


-- Configuring incomplete, errors occurred!

Fixed by manually modifying libs/doctest/CMakeLists.txt:

-cmake_minimum_required(VERSION 3.0)
+cmake_minimum_required(VERSION 3.15)

Though I don't know if this is the right way forward.

I'm running Arch Linux with CMake version 4.0.3.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions