From nobody Mon Mar 2 19:11:41 2026 X-Original-To: dev-commits-ports-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fPpSs4t8lz6T6Nk for ; Mon, 02 Mar 2026 19:11:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R12" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fPpSs4Mcrz3DfB for ; Mon, 02 Mar 2026 19:11:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772478701; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=gIB9HemT/BbEXTOBaSdfqu1dTDt20arwi3OjsX/HMHQ=; b=fwEQL3huXbrard23eEZvvH7shwufmBgyOR3+Yn62Cfp0MdseWJfNUi0a+GIroxcVrsagP6 xgxjWu89GFv3zkIRIw51Hsr07QbYD4zoHVhO9ElvE/P3JF7pDOfhk3crt65cs5aJhPCHbs 2+dm/yjl0CW/XBaq51F1y1Vby+T6WWzcndWVIo8RVlGeCOUy1URcmyRuqhHVHbfmgvvANb Z+QeyYMPDZoVmwHvHxvcj0it34sqO8RYDqEYd80f2h8G1YrdiXznPRgpm9p7QjGq0ihntz pStTZ1vBvamkgsrKdEIE9Xld2TszdKJ6fZOFEAMrG3rBO0w5BZK4nhuue+L+FA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1772478701; a=rsa-sha256; cv=none; b=a6cBMAXoDSq2Rva4qwRUnOjEJBQN5nv767RRQox7/r5lbtFBBPa5T0uC6thCR4vN/b+tF+ yGzQMRjE6pSsWOe0wxU41yJYCw3ryUmxKdt9PrwM7Bw203h2hKh4GEQuPBZE5ydWy/Ep30 DJIoEmfq386V83wZCM2uoy64VpqbgryUTCmxqB16+PdMZmv9Yf6hiRo8LbGuwqdItnI9QL IsC1LhOCqLOi/6FO6vf6Hu3Q6VdYO7c7bqenAQoj3KvMUWSp7tZijKBKaly8w+vwyS+Kct KLxTpOF6uRrPTA7D4lnrGBxxJ5i8xXV+YGIsD/J6OIUow0BNwUd2BeoPI52sTQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1772478701; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=gIB9HemT/BbEXTOBaSdfqu1dTDt20arwi3OjsX/HMHQ=; b=vIe6YPWULCEk5XR7e4t9Sfo3cBff9zMOw18d0Nkjrxa4Ug5OTJI7+MDkmH9hlbzJzKlt5W XQqcpKUoGaZTbZBvrx1U4wQZ6m15NDY9/ZaA4RFoSTJ1K7Wq/z+VFIPXx8QBJYueUTBhR1 5yb7jiCw1xUOJAhAbka07QmRch4OV3kZWhuVXc2NgugApJeRaDhkgOMUzG7Mhc0khbPvCH dmFEYPaFT2xGUWGaUXNI0pGS9WAa1iakplFT5IH6FNBzLiDaebZyvNJJM4uVSrMrx7+2n5 8jOoLPo0FH+x/r78TVcO8MXIvgUmpSUtXk3Dl2jNxqG22roiy3xxKvqkcysLsw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fPpSs3tgVznGN for ; Mon, 02 Mar 2026 19:11:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 1a318 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Mon, 02 Mar 2026 19:11:41 +0000 To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Gleb Popov Subject: git: 28d3c9802b42 - main - emulators/qemu-devel: Make the port a bit more in line with emulators/qemu and enable testing List-Id: Commits to the main branch of the FreeBSD ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-ports-main@freebsd.org Sender: owner-dev-commits-ports-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: arrowd X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 28d3c9802b4210bb96a07277715b77d9b28e9cbd Auto-Submitted: auto-generated Date: Mon, 02 Mar 2026 19:11:41 +0000 Message-Id: <69a5e0ed.1a318.6531d594@gitrepo.freebsd.org> The branch main has been updated by arrowd: URL: https://cgit.FreeBSD.org/ports/commit/?id=28d3c9802b4210bb96a07277715b77d9b28e9cbd commit 28d3c9802b4210bb96a07277715b77d9b28e9cbd Author: Gleb Popov AuthorDate: 2026-02-25 15:23:52 +0000 Commit: Gleb Popov CommitDate: 2026-03-02 19:11:06 +0000 emulators/qemu-devel: Make the port a bit more in line with emulators/qemu and enable testing Approved by: bofh (maintainer) Differential Revision: https://reviews.freebsd.org/D55511 --- emulators/qemu-devel/Makefile | 11 ++++--- ...tch-tests_functional_qemu__test_____init____.py | 11 +++++++ ...patch-tests_functional_qemu__test_decorators.py | 35 ++++++++++++++++++++++ ...patch-tests_functional_x86__64_test__memlock.py | 18 +++++++++++ 4 files changed, 71 insertions(+), 4 deletions(-) diff --git a/emulators/qemu-devel/Makefile b/emulators/qemu-devel/Makefile index 16bd4f7a9ad3..58c4617a073f 100644 --- a/emulators/qemu-devel/Makefile +++ b/emulators/qemu-devel/Makefile @@ -23,7 +23,7 @@ LIB_DEPENDS= libepoxy.so:graphics/libepoxy \ libslirp.so:net/libslirp USES= bison compiler:c11 cpe gmake gnome iconv:wchar_t localbase:ldflags \ - ninja perl5 pkgconfig python:build shebangfix tar:xz xorg + ninja:build perl5 pkgconfig python:build shebangfix tar:xz xorg USE_GITLAB= yes GL_ACCOUNT= qemu-project GL_TAGNAME= 9ef49528b5286f078061b52ac41e0ca19fa10e36 @@ -35,7 +35,6 @@ GL_TUPLE= qemu-project:keycodemapdb:f5772a62ec52591ff6870b7e8ef32482371f22c6:key qemu-project:berkeley-testfloat-3:e7af9751d9f9fd3b47911f51a5cfd08af256a9ab:berkeleytestfloat3/subprojects/berkeley-testfloat-3 USE_GNOME= cairo glib20 USE_PERL5= build -USE_PYTHON= distutils noflavors USE_XORG= pixman SHEBANG_FILES= scripts/xml-preprocess.py @@ -155,10 +154,11 @@ post-patch-CDROM_DMA-off: @${REINPLACE_CMD} -e '/USE_DMA_CDROM/d' ${WRKSRC}/include/hw/ide/internal.h do-build: - cd ${WRKSRC} && ${GMAKE} +# Don't build with -j, because the development branch of QEMU regresses from time to time + cd ${WRKSRC} && ${SETENVI} ${WRK_ENV} ${GMAKE} do-install: - cd ${WRKSRC} && ${SETENV} DESTDIR=${STAGEDIR} ${GMAKE} install + cd ${WRKSRC} && ${SETENVI} ${WRK_ENV} DESTDIR=${STAGEDIR} ${GMAKE} install .if !target(post-install) post-install: @@ -170,4 +170,7 @@ post-install-DOCS-on: @(cd ${WRKSRC} && ${COPYTREE_SHARE} docs ${STAGEDIR}${DOCSDIR}/) .endif +do-test: + cd ${WRKSRC} && ${SETENVI} ${WRK_ENV} ${GMAKE} test + .include diff --git a/emulators/qemu-devel/files/patch-tests_functional_qemu__test_____init____.py b/emulators/qemu-devel/files/patch-tests_functional_qemu__test_____init____.py new file mode 100644 index 000000000000..ece7c08f4235 --- /dev/null +++ b/emulators/qemu-devel/files/patch-tests_functional_qemu__test_____init____.py @@ -0,0 +1,11 @@ +--- tests/functional/qemu_test/__init__.py.orig 2025-11-25 22:22:39 UTC ++++ tests/functional/qemu_test/__init__.py +@@ -16,7 +16,7 @@ from .decorators import skipIfMissingCommands, skipIfN + from .decorators import skipIfMissingCommands, skipIfNotMachine, \ + skipFlakyTest, skipUntrustedTest, skipBigDataTest, skipSlowTest, \ + skipIfMissingImports, skipIfOperatingSystem, skipLockedMemoryTest, \ +- skipIfMissingEnv ++ skipIfMissingEnv, skipIfInsideFreeBSDJail + from .archive import archive_extract + from .uncompress import uncompress + from .gdb import GDB diff --git a/emulators/qemu-devel/files/patch-tests_functional_qemu__test_decorators.py b/emulators/qemu-devel/files/patch-tests_functional_qemu__test_decorators.py new file mode 100644 index 000000000000..d5901a0da1a2 --- /dev/null +++ b/emulators/qemu-devel/files/patch-tests_functional_qemu__test_decorators.py @@ -0,0 +1,35 @@ +--- tests/functional/qemu_test/decorators.py.orig 2025-11-25 22:22:39 UTC ++++ tests/functional/qemu_test/decorators.py +@@ -6,6 +6,7 @@ import resource + import os + import platform + import resource ++import subprocess + from unittest import skipIf, skipUnless + + from .cmd import which +@@ -165,3 +166,24 @@ def skipLockedMemoryTest(locked_memory): + ulimit_memory == resource.RLIM_INFINITY or ulimit_memory >= locked_memory * 1024, + f'Test required {locked_memory} kB of available locked memory', + ) ++ ++def skipIfInsideFreeBSDJail(): ++ ''' ++ Decorator to skip execution in a FreeBSD jail ++ ++ @skipIfInsideFreeBSDJail() ++ ''' ++ jailed = False ++ try: ++ result = subprocess.run( ++ ['sysctl', '-n', 'security.jail.jailed'], ++ capture_output=True, ++ text=True, ++ check=True ++ ) ++ jailed = result.stdout.strip() == '1' ++ except Exception: ++ pass ++ ++ return skipIf(platform.system() == 'FreeBSD' and jailed, ++ 'running inside the FreeBSD jail') diff --git a/emulators/qemu-devel/files/patch-tests_functional_x86__64_test__memlock.py b/emulators/qemu-devel/files/patch-tests_functional_x86__64_test__memlock.py new file mode 100644 index 000000000000..135f238fa18c --- /dev/null +++ b/emulators/qemu-devel/files/patch-tests_functional_x86__64_test__memlock.py @@ -0,0 +1,18 @@ +--- tests/functional/x86_64/test_memlock.py.orig 2025-11-25 22:22:39 UTC ++++ tests/functional/x86_64/test_memlock.py +@@ -14,13 +14,14 @@ from qemu_test import QemuSystemTest + from typing import Dict + + from qemu_test import QemuSystemTest +-from qemu_test import skipLockedMemoryTest ++from qemu_test import skipLockedMemoryTest, skipIfInsideFreeBSDJail + + + STATUS_VALUE_PATTERN = re.compile(r'^(\w+):\s+(\d+) kB', re.MULTILINE) + + + @skipLockedMemoryTest(2_097_152) # 2GB ++@skipIfInsideFreeBSDJail() + class MemlockTest(QemuSystemTest): + """ + Runs a guest with memlock options.