v4hn
7
Thank you a lot for the structured approach and good communication @sloretz .
It’s by far the most impactful end-of-distribution action for an OpenRobotics’s based software distribution so the clear structure is very much appreciated!
The reason is correct but the conclusion is wrong.
I urge maintainers to leave the C++ standard unspecified in the build system and remove existing definitions.
A big part of patches pushed in the ROS-O repositories are to ensure code will still compile when log4cxx started requiring c++17 - various other dependencies following through later.
There is no reason to require C++14 explicitly because it is already the compiler default in Ubuntu 20.04. Specifying C++17 might seem better - but that just means everything breaks again when libraries expose concept definitions and require C++20.
The if(NOT CMAKE_CXX_STANDARD) approach quoted above is possible, but it still means that things will break for every single person trying to build the defaults because they have to specify the standard when building their workspace.
3 Likes