cmkr
cmkr copied to clipboard
Modern build system based on CMake and TOML.
```toml [cmake] version = "3.15" cmkr-include = ["cmake/cmkr.cmake"] ``` This silently removes the cmkr include from the `CMakeLists.txt` instead of erroring. Only an empty string/false should do that.
Currently `${xxx_SOURCE_DIR}/blah/*.cpp` doesn't work because the file doesn't exist in the cmkr universe. Most likely this would have to be expanded to a GLOB expression (which is not ideal)
Potentially useful: https://discourse.cmake.org/t/add-dependency-to-zero-check-solved/5957
``` [project] name = "cmkr_printup_bug" [target.cmkr_printup_bug] type = "executable" sources = ["src/cmkr_printup_bug/*.cpp"] compile-features = ["cxx_std_11"] ``` (presumably this errors if `src/cmkr_printup_bug` doesn't exist
This isn't supported by CMake, but can help prevent annoying linker errors. The implementation should do: ``` if(NOT TARGET target) message(FATAL_ERROR "No such target: target") endif() ``` Before calling `target_link_libraries`.
Vcpkg ports support versioning. It seems like the current official way of listing versions is to run a git command line `git blame -l versions/-/.json`. There's also 3rd party sites...
```toml [fetch-content.zydis] git = "https://github.com/zyantific/zasm" ``` This should warn the user that the github project name `zasm` does not match the content name `zydis`
For multi-config generators there is an annoying thing that you cannot easily make debug/release-only flags. The idea would be: ```toml [target.foo] type = "executable" sources = ["..."] debug.compile-options = ["/DEBUGME"]...
Currently a `[project]` causes automatic regeneration to stop (for consistency reasons, you don't want to regenerate another cmkr project's files). Can be solved like this: ``` [project] name = "root"...