summaryrefslogtreecommitdiffstats
path: root/Modules/FindwxWidgets.cmake
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2019-11-13 14:38:00 (GMT)
committerKitware Robot <kwrobot@kitware.com>2019-11-13 14:38:48 (GMT)
commita0212382c98c9e76190892ba76441ed2668ec6ba (patch)
tree6f97f2500c4db7c97a23b7356a98b6f57114409a /Modules/FindwxWidgets.cmake
parenta1216139f800a403fa04478a79162d2ca0c6a2f8 (diff)
parentfe54989fcdd03a1f9bd674b31bac3a95a52a0fd5 (diff)
downloadCMake-a0212382c98c9e76190892ba76441ed2668ec6ba.zip
CMake-a0212382c98c9e76190892ba76441ed2668ec6ba.tar.gz
CMake-a0212382c98c9e76190892ba76441ed2668ec6ba.tar.bz2
Merge topic 'FindwxWidgets-qt' into release-3.16
fe54989fcd FindwxWidgets: Add support for wxQt Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !4038
Diffstat (limited to 'Modules/FindwxWidgets.cmake')
-rw-r--r--Modules/FindwxWidgets.cmake48
1 files changed, 26 insertions, 22 deletions
diff --git a/Modules/FindwxWidgets.cmake b/Modules/FindwxWidgets.cmake
index fd69e21..10af1f2 100644
--- a/Modules/FindwxWidgets.cmake
+++ b/Modules/FindwxWidgets.cmake
@@ -243,22 +243,24 @@ if(wxWidgets_FIND_STYLE STREQUAL "win32")
#-------------------------------------------------------------------
#
# Get filename components for a configuration. For example,
- # if _CONFIGURATION = mswunivud, then _UNV=univ, _UCD=u _DBG=d
- # if _CONFIGURATION = mswu, then _UNV="", _UCD=u _DBG=""
+ # if _CONFIGURATION = mswunivud, then _PF="msw", _UNV=univ, _UCD=u _DBG=d
+ # if _CONFIGURATION = mswu, then _PF="msw", _UNV="", _UCD=u _DBG=""
#
- macro(WX_GET_NAME_COMPONENTS _CONFIGURATION _UNV _UCD _DBG)
+ macro(WX_GET_NAME_COMPONENTS _CONFIGURATION _PF _UNV _UCD _DBG)
+ DBG_MSG_V(${_CONFIGURATION})
string(REGEX MATCH "univ" ${_UNV} "${_CONFIGURATION}")
- string(REGEX REPLACE "msw.*(u)[d]*$" "u" ${_UCD} "${_CONFIGURATION}")
+ string(REGEX REPLACE "[msw|qt].*(u)[d]*$" "u" ${_UCD} "${_CONFIGURATION}")
if(${_UCD} STREQUAL ${_CONFIGURATION})
set(${_UCD} "")
endif()
string(REGEX MATCH "d$" ${_DBG} "${_CONFIGURATION}")
+ string(REGEX MATCH "^[msw|qt]*" ${_PF} "${_CONFIGURATION}")
endmacro()
#
# Find libraries associated to a configuration.
#
- macro(WX_FIND_LIBS _UNV _UCD _DBG)
+ macro(WX_FIND_LIBS _PF _UNV _UCD _DBG)
DBG_MSG_V("m_unv = ${_UNV}")
DBG_MSG_V("m_ucd = ${_UCD}")
DBG_MSG_V("m_dbg = ${_DBG}")
@@ -310,13 +312,13 @@ if(wxWidgets_FIND_STYLE STREQUAL "win32")
# Find wxWidgets monolithic library.
find_library(WX_mono${_DBG}
NAMES
- wxmsw${_UNV}31${_UCD}${_DBG}
- wxmsw${_UNV}30${_UCD}${_DBG}
- wxmsw${_UNV}29${_UCD}${_DBG}
- wxmsw${_UNV}28${_UCD}${_DBG}
- wxmsw${_UNV}27${_UCD}${_DBG}
- wxmsw${_UNV}26${_UCD}${_DBG}
- wxmsw${_UNV}25${_UCD}${_DBG}
+ wx${_PF}${_UNV}31${_UCD}${_DBG}
+ wx${_PF}${_UNV}30${_UCD}${_DBG}
+ wx${_PF}${_UNV}29${_UCD}${_DBG}
+ wx${_PF}${_UNV}28${_UCD}${_DBG}
+ wx${_PF}${_UNV}27${_UCD}${_DBG}
+ wx${_PF}${_UNV}26${_UCD}${_DBG}
+ wx${_PF}${_UNV}25${_UCD}${_DBG}
PATHS ${WX_LIB_DIR}
NO_DEFAULT_PATH
)
@@ -327,13 +329,13 @@ if(wxWidgets_FIND_STYLE STREQUAL "win32")
stc ribbon propgrid webview)
find_library(WX_${LIB}${_DBG}
NAMES
- wxmsw${_UNV}31${_UCD}${_DBG}_${LIB}
- wxmsw${_UNV}30${_UCD}${_DBG}_${LIB}
- wxmsw${_UNV}29${_UCD}${_DBG}_${LIB}
- wxmsw${_UNV}28${_UCD}${_DBG}_${LIB}
- wxmsw${_UNV}27${_UCD}${_DBG}_${LIB}
- wxmsw${_UNV}26${_UCD}${_DBG}_${LIB}
- wxmsw${_UNV}25${_UCD}${_DBG}_${LIB}
+ wx${_PF}${_UNV}31${_UCD}${_DBG}_${LIB}
+ wx${_PF}${_UNV}30${_UCD}${_DBG}_${LIB}
+ wx${_PF}${_UNV}29${_UCD}${_DBG}_${LIB}
+ wx${_PF}${_UNV}28${_UCD}${_DBG}_${LIB}
+ wx${_PF}${_UNV}27${_UCD}${_DBG}_${LIB}
+ wx${_PF}${_UNV}26${_UCD}${_DBG}_${LIB}
+ wx${_PF}${_UNV}25${_UCD}${_DBG}_${LIB}
PATHS ${WX_LIB_DIR}
NO_DEFAULT_PATH
)
@@ -514,6 +516,7 @@ if(wxWidgets_FIND_STYLE STREQUAL "win32")
if(BUILD_SHARED_LIBS)
find_path(wxWidgets_LIB_DIR
NAMES
+ qtu/wx/setup.h
msw/wx/setup.h
mswd/wx/setup.h
mswu/wx/setup.h
@@ -539,6 +542,7 @@ if(wxWidgets_FIND_STYLE STREQUAL "win32")
else()
find_path(wxWidgets_LIB_DIR
NAMES
+ qtu/wx/setup.h
msw/wx/setup.h
mswd/wx/setup.h
mswu/wx/setup.h
@@ -581,7 +585,7 @@ if(wxWidgets_FIND_STYLE STREQUAL "win32")
endif()
# Search for available configuration types.
- foreach(CFG mswunivud mswunivd mswud mswd mswunivu mswuniv mswu msw)
+ foreach(CFG mswunivud mswunivd mswud mswd mswunivu mswuniv mswu msw qt qtd qtu qtud)
set(WX_${CFG}_FOUND FALSE)
if(EXISTS ${WX_LIB_DIR}/${CFG})
list(APPEND WX_CONFIGURATION_LIST ${CFG})
@@ -621,7 +625,7 @@ if(wxWidgets_FIND_STYLE STREQUAL "win32")
endif()
# Get configuration parameters from the name.
- WX_GET_NAME_COMPONENTS(${wxWidgets_CONFIGURATION} UNV UCD DBG)
+ WX_GET_NAME_COMPONENTS(${wxWidgets_CONFIGURATION} PF UNV UCD DBG)
# Set wxWidgets lib setup include directory.
if(EXISTS ${WX_LIB_DIR}/${wxWidgets_CONFIGURATION}/wx/setup.h)
@@ -641,7 +645,7 @@ if(wxWidgets_FIND_STYLE STREQUAL "win32")
endif()
# Find wxWidgets libraries.
- WX_FIND_LIBS("${UNV}" "${UCD}" "${DBG}")
+ WX_FIND_LIBS("${PF}" "${UNV}" "${UCD}" "${DBG}")
if(WX_USE_REL_AND_DBG)
WX_FIND_LIBS("${UNV}" "${UCD}" "d")
endif()