Made global setting of CMake module path explicit.

This commit is contained in:
Camilla Berglund 2015-05-11 22:28:02 +02:00
parent 47592fbf42
commit 5f7f6319eb

View File

@ -72,7 +72,6 @@ if (GLFW_USE_EGL)
message(FATAL_ERROR "Unsupported client library")
endif()
set(CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/CMake/modules")
find_package(EGL REQUIRED)
if (NOT _GLFW_USE_OPENGL)
@ -84,6 +83,8 @@ else()
set(_GLFW_USE_OPENGL 1)
endif()
set(CMAKE_MODULE_PATH "${GLFW_SOURCE_DIR}/CMake/modules")
if (_GLFW_USE_OPENGL)
find_package(OpenGL REQUIRED)
elseif (_GLFW_USE_GLESV1)