Closed daljit46 closed 3 months ago
clang-tidy review says "All clean, LGTM! :+1:"
clang-tidy review says "All clean, LGTM! :+1:"
clang-tidy review says "All clean, LGTM! :+1:"
clang-tidy review says "All clean, LGTM! :+1:"
clang-tidy review says "All clean, LGTM! :+1:"
clang-tidy review says "All clean, LGTM! :+1:"
clang-tidy review says "All clean, LGTM! :+1:"
clang-tidy review says "All clean, LGTM! :+1:"
clang-tidy review says "All clean, LGTM! :+1:"
Previously we relied on
add_compile_options
andadd_compile_definitions
for defining compiler definitions and options for the entire project. This commit replaces that behaviour by defining a newmrtrix::common
INTERFACE library that links to all targets in the project (the library is linked tomrtrix::core
). This is more CMake-idiomatic and prevents the propagation of compiler definitions to targets that do not link tomrtrix::core
(useful when compiling MRtrix3 as a subproject of another project). Ideally, we should be using CMake presets for this kind of stuff, but we need to support CMake 3.16.