Dear Olaf,
First of all, thanks for your feedback. It’s really appreciated.
Yes, I definitively do agree with you. Modern CMake shall be preferred over the pre-Modern CMake style shown here.
This article is outdated and was written before I’ve learnt Modern CMake. After that, I wrote the following articles about it:
- https://code.egym.de/how-to-use-modern-cmake-for-an-app-lib-project-3c2ee6018cde
- https://code.egym.de/refactoring-a-cmake-build-system-9898c2030c3a
Thanks to your feedback, I remembered to update the article with a disclaimer about Modern CMake and to add the links for the more updated ones.
I’ll keep the article available, since it’s part of CMake’s history, it may be useful to show the disadvantages of pre-Modern CMake, and maybe help developers working on old code bases.