2020-02-19 22:28:44 +02:00
|
|
|
include(CMakePushCheckState)
|
2014-11-13 19:30:51 +02:00
|
|
|
include(CheckTypeSize)
|
2020-02-24 19:41:26 +00:00
|
|
|
include(CheckSymbolExists)
|
2021-09-18 18:49:01 +03:00
|
|
|
include(CheckLibraryExists)
|
2014-11-13 19:30:51 +02:00
|
|
|
|
|
|
|
find_program(some_x_program NAMES iceauth xrdb xterm)
|
|
|
|
if (NOT some_x_program)
|
2021-06-01 16:38:19 +03:00
|
|
|
set(some_x_program ${CMAKE_INSTALL_PREFIX}/bin/xrdb)
|
|
|
|
message("Warning: Could not determine X binary directory. Assuming ${CMAKE_INSTALL_PREFIX}/bin.")
|
2014-11-13 19:30:51 +02:00
|
|
|
endif (NOT some_x_program)
|
|
|
|
get_filename_component(proto_xbindir "${some_x_program}" PATH)
|
2022-04-01 19:36:01 +03:00
|
|
|
get_filename_component(xbindir "${proto_xbindir}" ABSOLUTE)
|
|
|
|
get_filename_component(xrootdir "${xbindir}" PATH)
|
2014-11-13 19:30:51 +02:00
|
|
|
set(XLIBDIR "${xrootdir}/lib/X11")
|
2015-07-11 21:27:27 +03:00
|
|
|
set(XKBDIR "${xrootdir}/share/X11")
|
2014-11-13 19:30:51 +02:00
|
|
|
|
2020-02-24 19:41:26 +00:00
|
|
|
check_function_exists(nice HAVE_NICE)
|
2014-11-13 19:30:51 +02:00
|
|
|
check_include_files(malloc.h HAVE_MALLOC_H)
|
2022-10-06 14:35:22 +03:00
|
|
|
kde4_bool_to_01(FONTCONFIG_FOUND HAVE_FONTCONFIG) # kcontrol/fonts
|
2022-09-27 16:47:13 +03:00
|
|
|
kde4_bool_to_01(FREETYPE_FOUND HAVE_FREETYPE) # kcontrol/fonts
|
|
|
|
kde4_bool_to_01(X11_Xcomposite_FOUND HAVE_XCOMPOSITE) # plasma, kwin
|
|
|
|
kde4_bool_to_01(X11_Xcursor_FOUND HAVE_XCURSOR) # many uses
|
|
|
|
kde4_bool_to_01(X11_Xdamage_FOUND HAVE_XDAMAGE) # kwin
|
|
|
|
kde4_bool_to_01(X11_Xfixes_FOUND HAVE_XFIXES) # klipper, kicker, kwin
|
2023-09-03 21:48:19 +03:00
|
|
|
kde4_bool_to_01(X11_Xkb_FOUND HAVE_XKB) # kglobalaccel
|
2022-09-27 16:47:13 +03:00
|
|
|
kde4_bool_to_01(X11_Xrandr_FOUND HAVE_XRANDR) # kwin
|
|
|
|
kde4_bool_to_01(X11_XSync_FOUND HAVE_XSYNC) # kwin
|
|
|
|
kde4_bool_to_01(X11_XRes_FOUND HAVE_XRES) # ksysguard
|
|
|
|
kde4_bool_to_01(X11_dpms_FOUND HAVE_DPMS) # kscreensaver
|