1
1
mirror of https://github.com/OpenVoiceOS/OpenVoiceOS synced 2024-12-14 09:55:13 +01:00
OpenVoiceOS/buildroot-patches/0009-qt5base-enable-ccache-via-configure-option.patch
2022-05-12 10:44:08 +02:00

27 lines
984 B
Diff

diff --git a/package/qt5/qt5base/qt5base.mk b/package/qt5/qt5base/qt5base.mk
index ef38d03253..cce92db81b 100644
--- a/package/qt5/qt5base/qt5base.mk
+++ b/package/qt5/qt5base/qt5base.mk
@@ -297,10 +297,9 @@ endef
endif
# This allows to use ccache when available
-define QT5BASE_CONFIGURE_HOSTCC
- $(SED) 's,^QMAKE_CC\s*=.*,QMAKE_CC = $(HOSTCC),' $(@D)/mkspecs/common/g++-base.conf
- $(SED) 's,^QMAKE_CXX\s*=.*,QMAKE_CXX = $(HOSTCXX),' $(@D)/mkspecs/common/g++-base.conf
-endef
+ifeq ($(BR2_CCACHE),y)
+QT5BASE_CONFIGURE_OPTS += -ccache
+endif
# Must be last so can override all options set by Buildroot
QT5BASE_CONFIGURE_OPTS += $(call qstrip,$(BR2_PACKAGE_QT5BASE_CUSTOM_CONF_OPTS))
@@ -316,7 +315,6 @@ define QT5BASE_CONFIGURE_CMDS
touch $(QT5BASE_ARCH_CONFIG_FILE)
$(QT5BASE_CONFIGURE_ARCH_CONFIG_LIBATOMIC)
$(QT5BASE_CONFIGURE_ARCH_CONFIG_LIBEXECINFO)
- $(QT5BASE_CONFIGURE_HOSTCC)
(cd $(@D); \
$(TARGET_MAKE_ENV) \
PKG_CONFIG="$(PKG_CONFIG_HOST_BINARY)" \