From bf5c0db35a06455182f6568ab2cfa69346f8b3a1 Mon Sep 17 00:00:00 2001 From: Jesse Van Gavere Date: Tue, 7 Feb 2023 18:17:10 +0100 Subject: [PATCH] package/qt6/qt6base: add support for fontconfig/harfbuzz Additionally the harfbuzz license file is added and the hash for this is also added to the hash file Signed-off-by: Jesse Van Gavere Signed-off-by: Angelo Compagnucci Signed-off-by: Thomas Petazzoni --- package/qt6/qt6base/Config.in | 17 +++++++++++++++++ package/qt6/qt6base/qt6base.hash | 1 + package/qt6/qt6base/qt6base.mk | 23 +++++++++++++++++++++++ 3 files changed, 41 insertions(+) diff --git a/package/qt6/qt6base/Config.in b/package/qt6/qt6base/Config.in index 1810b1586d..ac2058c901 100644 --- a/package/qt6/qt6base/Config.in +++ b/package/qt6/qt6base/Config.in @@ -59,6 +59,23 @@ config BR2_PACKAGE_QT6BASE_XCB comment "X.org XCB backend available if X.org is enabled" depends on !BR2_PACKAGE_XORG7 +config BR2_PACKAGE_QT6BASE_FONTCONFIG + bool "fontconfig support" + select BR2_PACKAGE_FONTCONFIG + help + This option enables Fontconfig support using the system + fontconfig library. + +config BR2_PACKAGE_QT6BASE_HARFBUZZ + bool "harfbuzz support" + select BR2_PACKAGE_HARFBUZZ if \ + BR2_TOOLCHAIN_HAS_SYNC_4 && \ + BR2_TOOLCHAIN_GCC_AT_LEAST_4_8 + help + This option enables HarfBuzz support (either system harfbuzz + if the toolchain supports __sync for 4 bytes, or the qt + provided one which avoids this dependency by using QAtomic). + endif config BR2_PACKAGE_QT6BASE_NETWORK diff --git a/package/qt6/qt6base/qt6base.hash b/package/qt6/qt6base/qt6base.hash index 6544a371c6..fedbbba79f 100644 --- a/package/qt6/qt6base/qt6base.hash +++ b/package/qt6/qt6base/qt6base.hash @@ -11,3 +11,4 @@ sha256 8ceb4b9ee5adedde47b31e975c1d90c73ad27b6b165a1dcd80c7c545eb65b903 LICENS sha256 da7eabb7bafdf7d3ae5e9f223aa5bdc1eece45ac569dc21b3b037520b4464768 LICENSES/LGPL-3.0-only.txt sha256 d040359701c01996a017d5c515678929cd1b0625e64cb86db44025fbb6cdf1fc LICENSES/MIT.txt sha256 40678d338ce53cd93f8b22b281a2ecbcaa3ee65ce60b25ffb0c462b0530846b2 LICENSES/Qt-GPL-exception-1.0.txt +sha256 2a886915de4f296cdae5ed67064f86dba01d0c55286d86e8487f2a5caaf40216 src/3rdparty/harfbuzz-ng/COPYING diff --git a/package/qt6/qt6base/qt6base.mk b/package/qt6/qt6base/qt6base.mk index bcf2464590..6c155a4abb 100644 --- a/package/qt6/qt6base/qt6base.mk +++ b/package/qt6/qt6base/qt6base.mk @@ -172,6 +172,29 @@ else QT6BASE_CONF_OPTS += -DFEATURE_xcb=OFF endif +ifeq ($(BR2_PACKAGE_QT6BASE_HARFBUZZ),y) +QT6BASE_CONF_OPTS += -DFEATURE_harfbuzz=ON +ifeq ($(BR2_TOOLCHAIN_HAS_SYNC_4),y) +# system harfbuzz in case __sync for 4 bytes is supported +QT6BASE_CONF_OPTS += -DQT_USE_BUNDLED_BundledHarfbuzz=OFF +QT6BASE_DEPENDENCIES += harfbuzz +else #BR2_TOOLCHAIN_HAS_SYNC_4 +# qt harfbuzz otherwise (using QAtomic instead) +QT6BASE_CONF_OPTS += -DQT_USE_BUNDLED_BundledHarfbuzz=ON +QT6BASE_LICENSE += , MIT (harfbuzz) +QT6BASE_LICENSE_FILES += src/3rdparty/harfbuzz-ng/COPYING +endif +else +QT6BASE_CONF_OPTS += -DFEATURE_harfbuzz=OFF +endif + +ifeq ($(BR2_PACKAGE_QT6BASE_FONTCONFIG),y) +QT6BASE_CONF_OPTS += -DFEATURE_fontconfig=ON +QT6BASE_DEPENDENCIES += fontconfig +else +QT6BASE_CONF_OPTS += -DFEATURE_fontconfig=OFF +endif + else QT6BASE_CONF_OPTS += -DFEATURE_gui=OFF endif