On Wednesday 09 November 2016 00:47:39 Albrecht Schlosser wrote: > On 08.11.2016 23:01 Nils Gladitz wrote: > > On 08.11.2016 20:26, Albrecht Schlosser wrote: > >> I'm a developer of a public GUI library (FLTK). In this position you > >> don't know anything about the availability of CMake versions on your > >> target platforms. Our intention is to keep cmake_minimum_required() as > >> low as possible. > > > > If you are intending to keep the required version as low as possible > > you'll already have a justification / reason for doing so. > > I can only assume that the reason is that you need to support ancient > > platforms which ship equally ancient versions of CMake and you don't > > want to bother your users to build or install custom newer versions of > > CMake. > > > > It doesn't matter what your reasons or justifications for it are (though > > I would hope they are valid and verified) but you have to decide on a > > minimum version that you can life with in the end. > > Basically that's a floating target. We need to evaluate this from time > to time and maybe adjust the required version.
You could have a look at the major distributions and what they ship. The oldest I have to support is RHEL 5, released first 2007, and that feels really ancient. But there are people out there which still run such systems. Centos 5 comes with CMake 2.6.4, Centos 6 with 2.8.12. OTOH, installing additional versions of CMake is really easy, thanks to the binary packages provided by Kitware (... which IIRC are built in a Docker Centos 5 container). Btw. I really appreciate your idea to keep the requirements low. :-) > >> That said, whenever you change a CMakeLists.txt file you should be > >> aware if the commands you use are compatible with the CMake version > >> you "require". There should be an easy way to find out in which > >> version a particular CMake command has been introduced. Only with this > >> information you can decide if you should use this fine command or > >> better find another way to do the task you're going to do. > > > > At this point you only have to refer to the documentation that actually > > corresponds to the version you decided to require. > > You'll only find commands and behaviours in that documentation that'll > > actually be available in your minimum version. > > Yep, that's simple, of course. But if there is a (new) command you want > to use it would be interesting to know the CMake version it was > introduced to _decide_ if you can or want to do without it or raise the > required version. I'm sure that we will raise the required version when > CMake gets (or got) a new feature we need to use. But we need the facts > to decide... You can have a look here, there is the documentation for all cmake versions back to 2.6: https://cmake.org/documentation/ Alex -- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/cmake
