git: 7cfb3aef37e8 - main - sysutils/inxi: add dmidecode only where it's supported

From: Piotr Kubaj <pkubaj_at_FreeBSD.org>
Date: Sun, 10 Oct 2021 18:33:44 UTC
The branch main has been updated by pkubaj:

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

commit 7cfb3aef37e8075bd8589a18cb53cc790868cf3f
Author:     Piotr Kubaj <pkubaj@FreeBSD.org>
AuthorDate: 2021-10-10 18:14:30 +0000
Commit:     Piotr Kubaj <pkubaj@FreeBSD.org>
CommitDate: 2021-10-10 18:14:30 +0000

    sysutils/inxi: add dmidecode only where it's supported
---
 sysutils/inxi/Makefile | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/sysutils/inxi/Makefile b/sysutils/inxi/Makefile
index 27f938bc6912..1b1fd3337e65 100644
--- a/sysutils/inxi/Makefile
+++ b/sysutils/inxi/Makefile
@@ -9,7 +9,6 @@ LICENSE=	GPLv3
 LICENSE_FILE=	${WRKSRC}/LICENSE.txt
 
 RUN_DEPENDS=	bind-tools>=0:dns/bind-tools \
-		dmidecode:sysutils/dmidecode \
 		mesa-demos>=0:graphics/mesa-demos \
 		p5-Cpanel-JSON-XS>=0:converters/p5-Cpanel-JSON-XS \
 		p5-HTTP-Tiny>=0:www/p5-HTTP-Tiny \
@@ -37,6 +36,12 @@ PORTDOCS=	${PORTNAME}.changelog README.txt
 
 OPTIONS_DEFINE=	DOCS
 
+.include <bsd.port.options.mk>
+
+.if ${ARCH} == aarch64 || ${ARCH} == amd64 || ${ARCH} == armv6 || ${ARCH} == armv7 || ${ARCH} == i386 || ${ARCH} == riscv64 || ${ARCH} == riscv64sf
+RUN_DEPENDS+=	dmidecode:sysutils/dmidecode
+.endif
+
 do-install:
 	${INSTALL_SCRIPT} ${WRKSRC}/${PORTNAME} ${STAGEDIR}${PREFIX}/bin
 	${INSTALL_MAN} ${WRKSRC}/${PORTNAME}.1 ${STAGEDIR}${MAN1PREFIX}/man/man1