-
Notifications
You must be signed in to change notification settings - Fork 487
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove all links that point to CMake use in a non-modern way. #16
Comments
For reference, according to https://repology.org/metapackage/cmake/versions, the only (major) distros where the default CMake package is older than 3 are CentOS 6/7 (CMake v2.8.12.2 in both) and Ubuntu 12.04 (CMake v2.8.7; the release is in extended security maintenance until April 2019 for Ubuntu Advantage customers). Note: Ubuntu 14.04's "cmake" package is at 2.8.12.2, but a "cmake3" package (v3.5.1) is available in the "universe" repository, so I guess that doesn't count. |
I think that the old not target based way of using CMake, despite considered a bad practice, is still a valid way, and there is no reason to remove the links. Maybe only adding some kind of deprecated tag or separating them in subsection about CMake 2.x will be enough? |
I think old cruft has to go. The target-based way is much more concise and dependencies are better understood and easily maintained. |
However I would appreciate links that demonstrate how we can convert the old format to the more modern style. Looking at the CMake code in some Open Source projects I contribute to, it's a pretty daunting task. It's a sad state of affairs that the official CMake tutorial (https://cmake.org/cmake-tutorial/) uses 2.6. |
Discussion about old CMake deprecation on Reddit, with one of the authors of CMake. |
That's sad. C++ build / package systems are a real problem (take it from Bjarne Stroustrup, not me), and in desperate need of modernizing. |
@gajop another way is to employ static analysis on CMake files. We do this in our company to continuously check ~1000 files and report violations (e.g. non-modern). We use cmake_check for that purpose. The tool will grow but you can already scan a full tree and report forbidden usage. |
onqtam#16 onqtam#16 asked to clean up the list and remove links that refer to material that does not follow modern cmake standards. I moved anything that either uses (except to say it's wrong) one of the following commands: - include_directories - add_definitions - add_compile_options Same thing if the project tries to set CMAKE_<LANG>_FLAGS. I did not remove modules repositories links unless they use the above in the README or examples.
#16 (#42) #16 asked to clean up the list and remove links that refer to material that does not follow modern cmake standards. I moved anything that either uses (except to say it's wrong) one of the following commands: - include_directories - add_definitions - add_compile_options Same thing if the project tries to set CMAKE_<LANG>_FLAGS. I did not remove modules repositories links unless they use the above in the README or examples.
Perhaps not right now but in a few months there should be a cleanup - its high time everybody upgraded to at least version 3
The text was updated successfully, but these errors were encountered: