summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMaarten Bent <MaartenBent@users.noreply.github.com>2023-10-08 16:22:33 (GMT)
committerBrad King <brad.king@kitware.com>2023-11-01 12:20:25 (GMT)
commitc5e3d12213f7362a99e29d58b2cd01f613206e50 (patch)
tree1523d25736b7e50a99afc916884a0797590ac544
parent625023cacee4aaaa9f991207b294b49336f1f646 (diff)
downloadCMake-c5e3d12213f7362a99e29d58b2cd01f613206e50.zip
CMake-c5e3d12213f7362a99e29d58b2cd01f613206e50.tar.gz
CMake-c5e3d12213f7362a99e29d58b2cd01f613206e50.tar.bz2
FindwxWidgets: Move wx-config specific checks inside UNIX find-style
-rw-r--r--Modules/FindwxWidgets.cmake40
1 files changed, 20 insertions, 20 deletions
diff --git a/Modules/FindwxWidgets.cmake b/Modules/FindwxWidgets.cmake
index 845845c..82ae07f 100644
--- a/Modules/FindwxWidgets.cmake
+++ b/Modules/FindwxWidgets.cmake
@@ -948,29 +948,29 @@ if(wxWidgets_FIND_STYLE STREQUAL "unix")
endif()
unset(_cygpath_exe CACHE)
endif()
-endif()
-# Check that all libraries are present, as wx-config does not check it
-set(_wx_lib_missing "")
-foreach(_wx_lib_ ${wxWidgets_LIBRARIES})
- if("${_wx_lib_}" MATCHES "^-l(.*)")
- set(_wx_lib_name "${CMAKE_MATCH_1}")
- unset(_wx_lib_found CACHE)
- find_library(_wx_lib_found NAMES ${_wx_lib_name} HINTS ${wxWidgets_LIBRARY_DIRS})
- if(_wx_lib_found STREQUAL _wx_lib_found-NOTFOUND)
- list(APPEND _wx_lib_missing ${_wx_lib_name})
- endif()
- unset(_wx_lib_found CACHE)
- endif()
-endforeach()
+ # Check that all libraries are present, as wx-config does not check it
+ set(_wx_lib_missing "")
+ foreach(_wx_lib_ ${wxWidgets_LIBRARIES})
+ if("${_wx_lib_}" MATCHES "^-l(.*)")
+ set(_wx_lib_name "${CMAKE_MATCH_1}")
+ unset(_wx_lib_found CACHE)
+ find_library(_wx_lib_found NAMES ${_wx_lib_name} HINTS ${wxWidgets_LIBRARY_DIRS})
+ if(_wx_lib_found STREQUAL _wx_lib_found-NOTFOUND)
+ list(APPEND _wx_lib_missing ${_wx_lib_name})
+ endif()
+ unset(_wx_lib_found CACHE)
+ endif()
+ endforeach()
-if (_wx_lib_missing)
- string(REPLACE ";" " " _wx_lib_missing "${_wx_lib_missing}")
- DBG_MSG_V("wxWidgets not found due to following missing libraries: ${_wx_lib_missing}")
- set(wxWidgets_FOUND FALSE)
- unset(wxWidgets_LIBRARIES)
+ if (_wx_lib_missing)
+ string(REPLACE ";" " " _wx_lib_missing "${_wx_lib_missing}")
+ DBG_MSG_V("wxWidgets not found due to following missing libraries: ${_wx_lib_missing}")
+ set(wxWidgets_FOUND FALSE)
+ unset(wxWidgets_LIBRARIES)
+ endif()
+ unset(_wx_lib_missing)
endif()
-unset(_wx_lib_missing)
# Check if a specific version was requested by find_package().
if(wxWidgets_FOUND)