Elektra
0.8.16
|
add_plugin
if we should drop the plugin (see below in Argument)Names for flag:
DEPENDENCIES
-> might be used for add_plugin
ASSEMBLE_DEPS
FIND_DEPS
-> not only finding happensPROCESS_DEPS
HANDLE_DEPS
DEPS_MODE
-> too generic, new terminologyCHECK_DEPS
-> not only checking happensDO_DEPS
-> sounds funnyFIND_PACKAGES
-> not only packages are subject to this phaseCOLLECT
-> needs NOTFIND_PHASE
-> needs NOTDEPENDENCY
-> ambiguousIntroduce a cmake process where all plugins are processed two times:
1.) collection phase (DEPENDENCY_PHASE
is OFF
), with:
ADDED_PLUGINS
REMOVED_PLUGINS
ADDED_DIRECTORIES
DEPENDENCY_PHASE
is ON
, only considering ADDED_DIRECTORIES
), with:Use following cmake variables for the phases:
COLLECTION_PHASE
.. collect all add_plugins
DEPENDENCY_PHASE
.. resolve all dependencies, do add_plugins
againADDTESTING_PHASE
.. (reserve for potential 3rd phase)Solves all the issues without adding too much complexity. Can be extended to three phases if we need that for tests (they need knowledge about which plugins actually were added)
Maintaining additional mappings is very time-consuming. Simply adding all plugins directories is problematic. It would:
find_package
only in the second phase