Skip to content

CMake configuration overhaul #133

@tmadlener

Description

@tmadlener

The cmake configuration of several ilcsoft packages is pretty old and could potentially profit from exploiting newer cmake functionalities and in general newer cmake paradigms, e.g. target based configurations. Since LCIO is at the very base of everything, it could serve as a good starting point to check what would need changing and could then serve as an example for other packages as well.

A few points that should be decided/considered beforehand:

  • Which minimum cmake version do we require? LCG releases 96 and 97 come with 3.14, which looks like it is probably the hardest constraint. The current stable version is 3.20, Ubuntu 20.04 has 3.16
  • "Deprecation strategy" for the old configuration. In principle the target based and XXX_LIBRARIES, XXX_INCLUDE_DIRS approach can co-exist (see, e.g. SIO, so that it should be possible to update this package by package without breaking everything while updating.

A more modern cmake configuration has the potential to make some of the cmake macros that are part of ilcsoft obsolete, as cmake can now handle many things for which these macros were originally designed by itself. To which degree we can remove these macros is hard to estimate and will be something we find out along the way.

Other TODOs (keeping them here because then they show up as X of Y in the overview):

  • Use FindPython to detect python
  • Make sure the BUILD_TESTING option is considered for all tests

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions