nigels-com/glew

CMakeLists is illformed

SpaceIm opened this issue · 0 comments

CMakeLists.txt of glew is illformed. cmake_minimum_required() then project() must be the first instructions in a CMakeLists (some specific instructions may be called between cmake_minimum_required() and project(), but it's an edge case).

Currently, glew CMakeLists defeats any cmake toolchain.

Moreover cmake_minimum_required has been updated in #391, but several explicit POLICIES have been kept, while it doesn't make sense anymore since bump of min CMake version automatically set these POLICIES to NEW.
It's also not clear why this bump was required. It's not because some distro provides a specific CMake version by default, that you have to bump min CMake version in a library. You bump min version depending on CMake policies you want, and CMake features you want to use, it doesn't make sense to hard fail with older CMake versions if not necessary.

If it was due to #388, well 3.5 is sufficient. 3.15 is also considered as a very good min version for CMake policies.