CMake: don't add -Wl,--no-undefined to LDFLAGS for clang+windows cases

from a patchset by Vladislav Dmitrievich Turbanov:
https://github.com/libsdl-org/SDL/pull/4062
This commit is contained in:
Ozkan Sezer 2021-03-04 18:44:04 +03:00
parent 3880174a9f
commit 34ecd71e80
1 changed files with 1 additions and 1 deletions

View File

@ -537,7 +537,7 @@ if(USE_GCC OR USE_CLANG)
set(CMAKE_REQUIRED_FLAGS "-Wl,--no-undefined")
check_c_compiler_flag("" HAVE_NO_UNDEFINED)
set(CMAKE_REQUIRED_FLAGS ${ORIG_CMAKE_REQUIRED_FLAGS})
if(HAVE_NO_UNDEFINED)
if(HAVE_NO_UNDEFINED AND NOT (USE_CLANG AND WINDOWS))
list(APPEND EXTRA_LDFLAGS "-Wl,--no-undefined")
endif()
endif()