diff --git a/CMakeLists.txt b/CMakeLists.txt index 12d39101..42478bca 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -345,7 +345,7 @@ IF(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID STREQUAL Clang) CHECK_CXX_COMPILER_FLAG("--param ssp-buffer-size=4" SSP_BUFFER_SIZE_FLAG) IF(SSP_BUFFER_SIZE_FLAG) - SET(MY_C_FLAGS ${MY_C_FLAGS} --param ssp-buffer-size=4) + SET(MY_C_FLAGS ${MY_C_FLAGS} "--param ssp-buffer-size=4") ENDIF() ENDIF() diff --git a/src/wx/CMakeLists.txt b/src/wx/CMakeLists.txt index 562da1d0..4906dd3c 100644 --- a/src/wx/CMakeLists.txt +++ b/src/wx/CMakeLists.txt @@ -87,13 +87,9 @@ ENDFOREACH() # check if this build of wx actually has OpenGL support -SET(CURRENT_CMAKE_REQUIRED_LIBRARIES ${CMAKE_REQUIRED_LIBRARIES}) -SET(CURRENT_CMAKE_REQUIRED_FLAGS ${CMAKE_REQUIRED_FLAGS}) -SET(CURRENT_CMAKE_REQUIRED_INCLUDES ${CMAKE_REQUIRED_INCLUDES}) -SET(CURRENT_CMAKE_REQUIRED_DEFINITIONS ${CMAKE_REQUIRED_DEFINITIONS}) - SET(CMAKE_REQUIRED_LIBRARIES ${MY_CXX_FLAGS} ${MY_C_FLAGS} ${MY_CXX_LINKER_FLAGS} ${MY_C_LINKER_FLAGS} ${CMAKE_REQUIRED_LIBRARIES} ${wxWidgets_LIBRARIES}) SET(CMAKE_REQUIRED_FLAGS ${CMAKE_REQUIRED_FLAGS} ${wxWidgets_CXX_FLAGS} ${MY_CXX_FLAGS} ${MY_C_FLAGS}) + SET(CMAKE_REQUIRED_INCLUDES ${CMAKE_REQUIRED_INCLUDES} ${wxWidgets_INCLUDE_DIRS}) FOREACH(DEF ${wxWidgets_DEFINITIONS}) @@ -120,11 +116,6 @@ IF(NOT WX_HAS_OPENGL) FIND_PACKAGE(wxWidgets REQUIRED) ENDIF() -SET(CMAKE_REQUIRED_LIBRARIES ${CURRENT_CMAKE_REQUIRED_LIBRARIES}) -SET(CMAKE_REQUIRED_FLAGS ${CURRENT_CMAKE_REQUIRED_FLAGS}) -SET(CMAKE_REQUIRED_INCLUDES ${CURRENT_CMAKE_REQUIRED_INCLUDES}) -SET(CMAKE_REQUIRED_DEFINITIONS ${CURRENT_CMAKE_REQUIRED_DEFINITIONS}) - # end of wx OpenGL check FOREACH(CXX_COMPILE_FLAG ${wxWidgets_CXX_FLAGS})