aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMuhammad Moinur Rahman <bofh@FreeBSD.org>2025-01-11 14:25:26 +0000
committerMuhammad Moinur Rahman <bofh@FreeBSD.org>2025-01-11 14:55:29 +0000
commitba7961f454325f729d11785e2f4a12ddff5b0f33 (patch)
tree8f8c3257b2b94639cd1538588c0e2ca6562a010c
parent44f5357c13c171ea1af2541fd879e9d90d5f1980 (diff)
emulators/qemu: Fix build on i386
- qemu@tools and qemu@guestagent were failing on i386 due to some headers not being installed on i386 which is fixed. - qemu@tools support compression with zstd which was disabled. Enabled it to support compression of release artifacts. [1] Reported by: dch [1]
-rw-r--r--emulators/qemu/Makefile17
-rw-r--r--emulators/qemu/pkg-plist-ga2
-rw-r--r--emulators/qemu/pkg-plist-tools2
3 files changed, 16 insertions, 5 deletions
diff --git a/emulators/qemu/Makefile b/emulators/qemu/Makefile
index 43b450e9a361..d378d3ddb44a 100644
--- a/emulators/qemu/Makefile
+++ b/emulators/qemu/Makefile
@@ -1,5 +1,6 @@
PORTNAME= qemu
DISTVERSION= 9.2.0
+PORTREVISION= 1
CATEGORIES= emulators
MASTER_SITES= https://download.qemu.org/
DIST_SUBDIR= qemu/${PORTVERSION}
@@ -16,11 +17,13 @@ ONLY_FOR_ARCHS= aarch64 amd64 powerpc64 powerpc64le
.endif
BUILD_DEPENDS= bash:shells/bash
+.if ${FLAVOR:U} != guestagent
+LIB_DEPENDS+= libzstd.so:archivers/zstd
+.endif
.if ${FLAVOR:U} != tools && ${FLAVOR:U} != guestagent
LIB_DEPENDS+= libfdt.so:sysutils/dtc \
libinotify.so:devel/libinotify \
- libslirp.so:net/libslirp \
- libzstd.so:archivers/zstd
+ libslirp.so:net/libslirp
.endif
.if (${FLAVOR:U} != nox11 && ${FLAVOR:U} != tools && ${FLAVOR:U} != guestagent)
LIB_DEPENDS+= libepoxy.so:graphics/libepoxy
@@ -114,7 +117,7 @@ CONFIGURE_ARGS+= --disable-attr \
--disable-vnc
.endif
.if ${FLAVOR:U} == tools
-CONFIGURE_ARGS+= --enable-tools
+CONFIGURE_ARGS+= --enable-tools --enable-zstd
.endif
CFLAGS:= ${CFLAGS:C/-fno-tree-vrp//}
@@ -216,6 +219,14 @@ X86_TARGETS_CONFIGURE_ON= --target-list='i386-softmmu i386-bsd-user x86_64-softm
.include <bsd.port.options.mk>
+.if ${FLAVOR:U} == tools || ${FLAVOR:U} == guestagent
+.if ${ARCH} == "i386"
+PLIST_SUB+= NO_I386="@comment "
+.else
+PLIST_SUB+= NO_I386=""
+.endif
+.endif
+
.if (empty(FLAVOR) || ${FLAVOR:U} == default || ${FLAVOR:U} == nox11) && \
(${FLAVOR:U} != tools || ${PKGNAMESUFFIX} != "-guest-agent")
.if ${ARCH} == "amd64"
diff --git a/emulators/qemu/pkg-plist-ga b/emulators/qemu/pkg-plist-ga
index 7d934bfea859..76fa57967f1f 100644
--- a/emulators/qemu/pkg-plist-ga
+++ b/emulators/qemu/pkg-plist-ga
@@ -1,5 +1,5 @@
bin/qemu-ga
-include/qemu-plugin.h
+%%NO_I386%%include/qemu-plugin.h
%%PORTDOCS%%share/man/man1/qemu.1.gz
%%PORTDOCS%%share/man/man7/qemu-block-drivers.7.gz
%%PORTDOCS%%share/man/man7/qemu-cpu-models.7.gz
diff --git a/emulators/qemu/pkg-plist-tools b/emulators/qemu/pkg-plist-tools
index 0be0420db843..2d227cf2fa0b 100644
--- a/emulators/qemu/pkg-plist-tools
+++ b/emulators/qemu/pkg-plist-tools
@@ -3,7 +3,7 @@ bin/qemu-img
bin/qemu-io
bin/qemu-nbd
bin/qemu-storage-daemon
-include/qemu-plugin.h
+%%NO_I386%%include/qemu-plugin.h
%%PORTDOCS%%share/man/man1/qemu.1.gz
%%PORTDOCS%%share/man/man1/qemu-img.1.gz
%%PORTDOCS%%share/man/man7/qemu-block-drivers.7.gz