summaryrefslogtreecommitdiffstats
path: root/Modules/FindX11.cmake
diff options
context:
space:
mode:
authorplanc <hubenchang0515@outlook.com>2022-03-08 07:15:25 (GMT)
committerBrad King <brad.king@kitware.com>2022-03-10 16:41:31 (GMT)
commitce28748ced4ed6778a730a9ca638c2d557dbc026 (patch)
tree6adbd72f6b20246bdf694fe79ee969063cc266d5 /Modules/FindX11.cmake
parentcbd36eac23628f74ae3b50f9d1b8a0478c3e317a (diff)
downloadCMake-ce28748ced4ed6778a730a9ca638c2d557dbc026.zip
CMake-ce28748ced4ed6778a730a9ca638c2d557dbc026.tar.gz
CMake-ce28748ced4ed6778a730a9ca638c2d557dbc026.tar.bz2
FindX11: add xcb-xtest and xcb-keysyms
Diffstat (limited to 'Modules/FindX11.cmake')
-rw-r--r--Modules/FindX11.cmake34
1 files changed, 33 insertions, 1 deletions
diff --git a/Modules/FindX11.cmake b/Modules/FindX11.cmake
index 5a9d2a0..8e5a5f1 100644
--- a/Modules/FindX11.cmake
+++ b/Modules/FindX11.cmake
@@ -34,6 +34,8 @@ and also the following more fine grained variables and targets:
X11_xcb_randr_INCLUDE_PATH, X11_xcb_randr_LIB, X11_xcb_randr_FOUND, X11::xcb_randr
X11_xcb_util_INCLUDE_PATH, X11_xcb_util_LIB, X11_xcb_util_FOUND, X11::xcb_util
X11_xcb_xfixes_INCLUDE_PATH, X11_xcb_xfixes_LIB, X11_xcb_xfixes_FOUND, X11::xcb_xfixes
+ X11_xcb_xtest_INCLUDE_PATH, X11_xcb_xtest_LIB, X11_xcb_xtest_FOUND, X11::xcb_xtest
+ X11_xcb_keysyms_INCLUDE_PATH, X11_xcb_keysyms_LIB,X11_xcb_keysyms_FOUND,X11::xcb_keysyms
X11_xcb_xkb_INCLUDE_PATH, X11_xcb_xkb_LIB, X11_xcb_xkb_FOUND, X11::xcb_xkb
X11_Xcomposite_INCLUDE_PATH, X11_Xcomposite_LIB, X11_Xcomposite_FOUND, X11::Xcomposite
X11_Xcursor_INCLUDE_PATH, X11_Xcursor_LIB, X11_Xcursor_FOUND, X11::Xcursor
@@ -84,7 +86,7 @@ and also the following more fine grained variables and targets:
Added the ``Xaw``, ``xcb_util``, and ``xcb_xfixes`` libraries.
.. versionadded:: 3.24
- Added the ``xcb_randr`` library.
+ Added the ``xcb_randr``, ``xcb_xtext``, and ``xcb_keysyms`` libraries.
#]=======================================================================]
@@ -134,6 +136,8 @@ if (UNIX)
find_path(X11_xcb_randr_INCLUDE_PATH xcb/randr.h ${X11_INC_SEARCH_PATH})
find_path(X11_xcb_util_INCLUDE_PATH xcb/xcb_aux.h ${X11_INC_SEARCH_PATH})
find_path(X11_xcb_xfixes_INCLUDE_PATH xcb/xfixes.h ${X11_INC_SEARCH_PATH})
+ find_path(X11_xcb_xtest_INCLUDE_PATH xcb/xtest.h ${X11_INC_SEARCH_PATH})
+ find_path(X11_xcb_keysyms_INCLUDE_PATH xcb/xcb_keysyms.h ${X11_INC_SEARCH_PATH})
find_path(X11_Xcomposite_INCLUDE_PATH X11/extensions/Xcomposite.h ${X11_INC_SEARCH_PATH})
find_path(X11_Xcursor_INCLUDE_PATH X11/Xcursor/Xcursor.h ${X11_INC_SEARCH_PATH})
find_path(X11_Xdamage_INCLUDE_PATH X11/extensions/Xdamage.h ${X11_INC_SEARCH_PATH})
@@ -188,6 +192,8 @@ if (UNIX)
find_library(X11_xcb_randr_LIB xcb-randr ${X11_LIB_SEARCH_PATH})
find_library(X11_xcb_util_LIB xcb-util ${X11_LIB_SEARCH_PATH})
find_library(X11_xcb_xfixes_LIB xcb-xfixes ${X11_LIB_SEARCH_PATH})
+ find_library(X11_xcb_xtest_LIB xcb-xtest ${X11_LIB_SEARCH_PATH})
+ find_library(X11_xcb_keysyms_LIB xcb-keysyms ${X11_LIB_SEARCH_PATH})
find_library(X11_xcb_xkb_LIB xcb-xkb ${X11_LIB_SEARCH_PATH})
find_library(X11_Xcomposite_LIB Xcomposite ${X11_LIB_SEARCH_PATH})
find_library(X11_Xcursor_LIB Xcursor ${X11_LIB_SEARCH_PATH})
@@ -299,6 +305,14 @@ if (UNIX)
set(X11_xcb_xfixes_FOUND TRUE)
endif ()
+ if (X11_xcb_xtest_LIB)
+ set(X11_xcb_xtest_FOUND TRUE)
+ endif ()
+
+ if (X11_xcb_keysyms_LIB)
+ set(X11_xcb_keysyms_FOUND TRUE)
+ endif ()
+
if (X11_xcb_xkb_LIB)
set(X11_xcb_xkb_FOUND TRUE)
endif ()
@@ -631,6 +645,20 @@ if (UNIX)
INTERFACE_LINK_LIBRARIES "X11::xcb")
endif ()
+ if (X11_xcb_xtest_FOUND AND NOT TARGET X11::xcb_xtest)
+ add_library(X11::xcb_xtest UNKNOWN IMPORTED)
+ set_target_properties(X11::xcb_xtest PROPERTIES
+ IMPORTED_LOCATION "${X11_xcb_xtest_LIB}"
+ INTERFACE_LINK_LIBRARIES "X11::xcb")
+ endif ()
+
+ if (X11_xcb_keysyms_FOUND AND NOT TARGET X11::xcb_keysyms)
+ add_library(X11::xcb_keysyms UNKNOWN IMPORTED)
+ set_target_properties(X11::xcb_keysyms PROPERTIES
+ IMPORTED_LOCATION "${X11_xcb_keysyms_LIB}"
+ INTERFACE_LINK_LIBRARIES "X11::xcb")
+ endif ()
+
if (X11_xcb_xkb_FOUND AND NOT TARGET X11::xcb_xkb)
add_library(X11::xcb_xkb UNKNOWN IMPORTED)
set_target_properties(X11::xcb_xkb PROPERTIES
@@ -853,6 +881,10 @@ if (UNIX)
X11_xcb_util_INCLUDE_PATH
X11_xcb_xfixes_LIB
X11_xcb_xfixes_INCLUDE_PATH
+ X11_xcb_xtest_LIB
+ X11_xcb_xtest_INCLUDE_PATH
+ X11_xcb_keysyms_LIB
+ X11_xcb_keysyms_INCLUDE_PATH
X11_xcb_xkb_LIB
X11_X11_xcb_LIB
X11_X11_xcb_INCLUDE_PATH