Build: cmake experiment
One of the goals of %next-stable-3.0 is to modernize our build system. This ticket is about making experiments with CMake (homepage, the repo on github has only 6.5k stars, but it's misleading, because it's only a mirror. For example, one guy posted CMake examples that have 12.1k stars).
Here's non-exhaustive list of things to try:
-
get rid of all autotools files -
implement CMake for part of the code (implementing it for everything would be a lot of work), so at least one binary could be linked
I was thinking that perhaps using kea-dhcp4 as a reference would be enough to make comparison. So implement cmake for all the libs needed for kea-dhcp4 and then the src/bin/dhcp4. This could be the bare bones minimum to do objective comparison between autotools and cmake.
As an additional result of this ticket, some metrics are expected:
- build time before/after changes
- configure time before/after change
- maybe file size/disk space used if there are any noticeable differences
- Does it work on Linux/FreeBSD/MacOS?
- subjective opinion: what was the learning experience (was the build system easy or hard to learn? was it well documented? easy to understand? easy to do what you wanted it to do?)
- subjective opinion: once the initial learning phase was over, was it easy/pleasant to work with this build system?
One important aspect is to check if the hooks still work. So it's essential to run some hook tests, before declaring the changes are done.
This is intended to be an experiment. Expect the code to be discarded. It is very much OK for the change be a bit hacky, incomplete and not working under some circumstances. We expect to do several experiments like that. Depending on their results, we will determine the next steps.