build-cpp / cmkr

Modern build system based on CMake and TOML.
https://cmkr.build
MIT License
431 stars 27 forks source link

[options] should also be conditions #37

Closed mrexodia closed 1 year ago

mrexodia commented 2 years ago

Currently you need to do extra work:

[options]
PROJECT_BUILD_TESTS = false

[conditions]
tests = "PROJECT_BUILD_TESTS"

[target.tests]
condition = "tests"
sources = ["src/tests.cpp"]

This could be:

[options]
PROJECT_BUILD_TESTS = false

[target.tests]
condition = "PROJECT_BUILD_TESTS"
sources = ["src/tests.cpp"]