view src/qt6-qttools-1-libclang.patch @ 6883:a0e9deadb221

Qt6 QtTools: Tolerate incomplete installation of libclang-dev on host. * qt6-qttools-1-libclang.patch: Skip checking for libclang if it won't be used. * qt6-tools.mk: Replace deprecated QT_BUILD_TOOLS_WHEN_CROSSCOMPILING flag with QT_FORCE_BUILD_TOOLS. * dist-files.mk: Add new patch file to list.
author Markus Mützel <markus.muetzel@gmx.de>
date Fri, 29 Sep 2023 10:51:23 +0200
parents
children
line wrap: on
line source

Don't check for libclang when building without it.

diff -urN qttools-everywhere-src-6.5.2/configure.cmake qttools-everywhere-src-6.5.2/configure.cmake.orig
--- qttools-everywhere-src-6.5.2/configure.cmake.orig	2023-07-07 14:29:26.000000000 +0200
+++ qttools-everywhere-src-6.5.2/configure.cmake	2023-09-29 10:39:40.324294579 +0200
@@ -17,7 +17,9 @@
 # Presumably because 6.0 ClangConfig.cmake files are not good enough?
 # In any case explicitly request a minimum version of 8.x for now, otherwise
 # building with CMake will fail at compilation time.
+if (QT_FEATURE_clang)
 qt_find_package(WrapLibClang 8 PROVIDED_TARGETS WrapLibClang::WrapLibClang)
+endif()
 # special case end
 
 if(TARGET WrapLibClang::WrapLibClang)