Simplify CMakeLists and plugin handling
- Introduce
add_subdirectory_if,add_component, andadd_component_ifsimilar to the framework. The later functions automatically adds the subdirectory name to the list of supported components. - Consistent names: all (optional) components are located in subdirectories of the corresponding name. The plugins are therefore located in
...Pluginsubdirectories instead of...Plugins. This change is only performed on the cmake level, headers paths are untouched to avoid breaking dependent software. To be considered in the future. - Centralize options and required packages in the main
CMakeLists.txtfile. By looking at this file you now see directly what can be configured and what is required. - Drop inconsistent/confusing options:
ACTS_FIND_QIETconflicts withREQUIREDin allfind_package(...)calls,PRINT_OPTIONSis pure duplication since the options are already listed both in the mainCMakeLists.txtfile and in theREADMEfile. - Extend the generated version header and use
.hppextension for consistency with the rest of the code base. This is a possible breaking change, but there seems to be no code that actually includes the file here. - Prefix all build options with
ACTS_...for consistency and to avoid conflicts with options from our packages. This is a breaking change.
Open questions:
- I would like to remove the automatic ccache setup. I don't think it belongs into the build instructions since it is a developer-dependent setting and can be easily enable using
CXX='ccache g++' cmake .... If we want to be able to include acts directly as a subproject in the framework, this also forces this setting on everything else which might not be what we want.
Fixes ACTS-374.
Edited by Moritz Kiehn