Fix CMake 3.0 - 3.6 support regression

Replaces `VERSION_GREATER_EQUAL` with `VERSION_EQUAL OR
VERSION_GREATER`.  `VERSION_GREATER_EQUAL` was only added in CMake 3.7.

Fixes #1584.
Closes #1585.
This commit is contained in:
Pablo Prietz 2019-10-24 12:04:18 +02:00 committed by Camilla Löwy
parent 82978bb3af
commit 4d0ae4ffa7
2 changed files with 5 additions and 1 deletions

View File

@ -339,6 +339,7 @@ skills.
- Santi Zupancic - Santi Zupancic
- Jonas Ådahl - Jonas Ådahl
- Lasse Öörni - Lasse Öörni
- Pablo Prietz
- All the unmentioned and anonymous contributors in the GLFW community, for bug - All the unmentioned and anonymous contributors in the GLFW community, for bug
reports, patches, feedback, testing and encouragement reports, patches, feedback, testing and encouragement

View File

@ -100,7 +100,10 @@ set_target_properties(glfw PROPERTIES
POSITION_INDEPENDENT_CODE ON POSITION_INDEPENDENT_CODE ON
FOLDER "GLFW3") FOLDER "GLFW3")
if (${CMAKE_VERSION} VERSION_GREATER_EQUAL "3.1.0") if (
${CMAKE_VERSION} VERSION_EQUAL "3.1.0" OR
${CMAKE_VERSION} VERSION_GREATER "3.1.0"
)
set_target_properties(glfw PROPERTIES C_STANDARD 99) set_target_properties(glfw PROPERTIES C_STANDARD 99)
else() else()
# Remove this fallback when removing support for CMake version less than 3.1 # Remove this fallback when removing support for CMake version less than 3.1