git: faf97a481bfd - main - devel/gammaray: make it possible to build without webengine

From: Piotr Kubaj <pkubaj_at_FreeBSD.org>
Date: Mon, 01 Nov 2021 02:41:53 UTC
The branch main has been updated by pkubaj:

URL: https://cgit.FreeBSD.org/ports/commit/?id=faf97a481bfd54f1ebaa205508234cedd6a0aaef

commit faf97a481bfd54f1ebaa205508234cedd6a0aaef
Author:     Piotr Kubaj <pkubaj@FreeBSD.org>
AuthorDate: 2021-11-01 02:40:27 +0000
Commit:     Piotr Kubaj <pkubaj@FreeBSD.org>
CommitDate: 2021-11-01 02:40:27 +0000

    devel/gammaray: make it possible to build without webengine
---
 devel/gammaray/Makefile  | 12 ++++++++++--
 devel/gammaray/pkg-plist |  2 +-
 2 files changed, 11 insertions(+), 3 deletions(-)

diff --git a/devel/gammaray/Makefile b/devel/gammaray/Makefile
index 9de624d0149a..851930070528 100644
--- a/devel/gammaray/Makefile
+++ b/devel/gammaray/Makefile
@@ -14,14 +14,22 @@ USES=		cmake kde:5 pkgconfig qt:5
 
 USE_QT=		3d concurrent core declarative designer gui help linguisttools \
 		location network printsupport script scripttools svg uiplugin \
-		webchannel webengine widgets xml buildtools_build qdoc_build \
-		qmake_build
+		webchannel widgets xml buildtools_build qdoc_build qmake_build
 USE_KDE=	coreaddons syntaxhighlighting
 
 USE_GITHUB=	yes
 GH_ACCOUNT=	KDAB
 GH_PROJECT=	GammaRay
 
+.include <bsd.port.options.mk>
+
+.if ${ARCH} == aarch64 || ${ARCH} == amd64 || ${ARCH} == i386
+PLIST_SUB=	WEBENGINE=""
+USE_QT+=	webengine
+.else
+PLIST_SUB=	WEBENGINE="@comment "
+.endif
+
 PLIST_SUB+=	ARCH=${ARCH:S/amd64/x86_64/} \
 		PORTMAJMIN=${PORTVERSION:C/(.*)\..*/\1/} \
 		PORTVERSION=${PORTVERSION} \
diff --git a/devel/gammaray/pkg-plist b/devel/gammaray/pkg-plist
index fc21ed34f78c..3c34c48a9c47 100644
--- a/devel/gammaray/pkg-plist
+++ b/devel/gammaray/pkg-plist
@@ -117,7 +117,7 @@ lib/gammaray/%%PORTMAJMIN%%/qt%%QTVER%%-%%ARCH%%/gammaray_timertop_ui_plugin.so
 lib/gammaray/%%PORTMAJMIN%%/qt%%QTVER%%-%%ARCH%%/gammaray_translatorinspector_ui.so
 lib/gammaray/%%PORTMAJMIN%%/qt%%QTVER%%-%%ARCH%%/gammaray_translatorinspector.so
 lib/gammaray/%%PORTMAJMIN%%/qt%%QTVER%%-%%ARCH%%/gammaray_webinspector_plugin.so
-lib/gammaray/%%PORTMAJMIN%%/qt%%QTVER%%-%%ARCH%%/gammaray_webinspector_ui_plugin.so
+%%WEBENGINE%%lib/gammaray/%%PORTMAJMIN%%/qt%%QTVER%%-%%ARCH%%/gammaray_webinspector_ui_plugin.so
 lib/gammaray/%%PORTMAJMIN%%/qt%%QTVER%%-%%ARCH%%/gammaray_widgetinspector_plugin.so
 lib/gammaray/%%PORTMAJMIN%%/qt%%QTVER%%-%%ARCH%%/gammaray_widgetinspector_ui_plugin.so
 lib/gammaray/%%PORTMAJMIN%%/qt%%QTVER%%-%%ARCH%%/gammaray_wlcompositorinspector_ui.so