]> git.lyx.org Git - lyx.git/commitdiff
Cmake build: Add defines for HAVE_XCB_XCB_H and HAVE_LIBXCB
authorKornel Benko <kornel@lyx.org>
Thu, 29 Aug 2024 12:08:39 +0000 (14:08 +0200)
committerKornel Benko <kornel@lyx.org>
Thu, 29 Aug 2024 12:08:39 +0000 (14:08 +0200)
development/cmake/ConfigureChecks.cmake
development/cmake/config.h.cmake
src/CMakeLists.txt

index 9062372c38e107156a7e561bce340045b0cd53e0..ed9328fdcda3954cc3e3ff61af290d2b2758a240 100644 (file)
@@ -28,7 +28,7 @@ test_big_endian(WORDS_BIGENDIAN)
 set(Include_Defines)
 foreach(_h_file aspell.h aspell/aspell.h limits.h locale.h
        stdlib.h sys/stat.h sys/time.h sys/types.h sys/utime.h
-       sys/socket.h unistd.h inttypes.h utime.h string.h argz.h)
+       sys/socket.h unistd.h inttypes.h utime.h string.h argz.h xcb/xcb.h)
        string(REGEX REPLACE "[/\\.]" "_" _hf ${_h_file})
        string(TOUPPER ${_hf} _HF)
        check_include_files(${_h_file} HAVE_${_HF})
index 15bceaac46e728ff0c71069360d1627d65cf4920..856f9a8acc9d2668aaee3db2e0fae4b8aff73c18 100644 (file)
@@ -91,10 +91,13 @@ ${Include_used_spellchecker}
 // Define to 1 if enchant is version 2.x at least
 #cmakedefine HAVE_ENCHANT2 1
 
-#endif // config.h guard
+// Define to 1 if have xcb library
+#cmakedefine HAVE_LIBXCB ${HAVE_LIBXCB}
 
 #define MYTHES_H_LOCATION <${MYTHES_DIR}/mythes.hxx>
 
+#endif // config.h guard
+
 // Unguarded cleanup of global namespace:
 
 #ifdef ColorMode
index 4debde6c16c65e0ab228825de4542834e06426e5..b89ecee2f6b2aee95a1fee5fbdf258a91ee401de 100644 (file)
@@ -148,7 +148,6 @@ if(QT_USES_X11)
   find_package(X11 REQUIRED)
   target_link_libraries(${_lyx} ${X11_X11_LIB}) # we need it because we use XSendEvent
   if(HAVE_QT5_X11_EXTRAS)
-    find_library(XCB_LIBRARY NAMES xcb)
     if (XCB_LIBRARY MATCHES "NOTFOUND")
       message(FATAL_ERROR "Need xcb library to use with QT5_X11_EXTRAS")
     endif()