CMake: fixed a failure to reset CMAKE_REQUIRED_FLAGS (thanks, Martin!).
authorRyan C. Gordon <icculus@icculus.org>
Tue, 29 Dec 2015 00:36:03 -0500
changeset 9981a443c97eb294
parent 9980 224187458d03
child 9982 9145e51b15bb
CMake: fixed a failure to reset CMAKE_REQUIRED_FLAGS (thanks, Martin!).

This would break Emscripten builds with the CMake project files (etc).

Fixes Bugzilla #3197.
CMakeLists.txt
     1.1 --- a/CMakeLists.txt	Tue Dec 29 00:24:37 2015 -0500
     1.2 +++ b/CMakeLists.txt	Tue Dec 29 00:36:03 2015 -0500
     1.3 @@ -382,7 +382,7 @@
     1.4  
     1.5    set(CMAKE_REQUIRED_FLAGS "-Wl,--no-undefined")
     1.6    check_c_compiler_flag("" HAVE_NO_UNDEFINED)
     1.7 -  set(CMAKE_REQUIRED_FLAGS)
     1.8 +  set(CMAKE_REQUIRED_FLAGS ${ORIG_CMAKE_REQUIRED_FLAGS})
     1.9    if(HAVE_NO_UNDEFINED)
    1.10      list(APPEND EXTRA_LDFLAGS "-Wl,--no-undefined")
    1.11    endif()