diff --git a/CMakeLists.txt b/CMakeLists.txt index b7a195b5..eecaca7a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -277,6 +277,15 @@ IF(WIN32) INCLUDE_DIRECTORIES("${CMAKE_SOURCE_DIR}/dependencies/mingw-xaudio/include") ENDIF() +IF(MSVC) + SET(DEPS_MSVC "${CMAKE_SOURCE_DIR}/dependencies/msvc") + IF(NOT EXISTS "${DEPS_MSVC}" AND EXISTS "${CMAKE_SOURCE_DIR}/.git") + MESSAGE(FATAL_ERROR "Please pull in git submodules, e.g.\nrun: git submodule update --init --recursive") + ENDIF() + + INCLUDE_DIRECTORIES("${DEPS_MSVC}") # for GL/glext.h +ENDIF(MSVC) + # Compiler flags IF(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID STREQUAL Clang) diff --git a/src/wx/CMakeLists.txt b/src/wx/CMakeLists.txt index fb78fcf9..5099a66e 100644 --- a/src/wx/CMakeLists.txt +++ b/src/wx/CMakeLists.txt @@ -149,10 +149,6 @@ ENDIF(WIN32 AND ENABLE_DIRECTX) # contrib widgets include_directories(widgets) -IF(MSVC) - include_directories(../../dependencies/msvc) # for GL/glext.h -ENDIF(MSVC) - # for out-of-tree builds, grab includes from both target and source dirs include_directories(${CMAKE_CURRENT_BINARY_DIR}) include_directories(${CMAKE_CURRENT_SOURCE_DIR})