From 5eab7c5097a830d6ac26485ec5b80e384f2044c7 Mon Sep 17 00:00:00 2001 From: Daan De Meyer Date: Fri, 5 Jul 2024 19:16:31 +0200 Subject: [PATCH 1/2] mkosi: Make .autorelabel file empty The contents of this file are passed as arguments to fixfiles so let's remove the comment as otherwise fixfiles just crashes. --- mkosi.images/system/mkosi.extra/.autorelabel | 1 - 1 file changed, 1 deletion(-) diff --git a/mkosi.images/system/mkosi.extra/.autorelabel b/mkosi.images/system/mkosi.extra/.autorelabel index bd4fba4dfe..e69de29bb2 100644 --- a/mkosi.images/system/mkosi.extra/.autorelabel +++ b/mkosi.images/system/mkosi.extra/.autorelabel @@ -1 +0,0 @@ -# SPDX-License-Identifier: LGPL-2.1-or-later From 575f954b5d0e03d41fe08ce2a7d85b868e89b904 Mon Sep 17 00:00:00 2001 From: Daan De Meyer Date: Fri, 5 Jul 2024 19:20:42 +0200 Subject: [PATCH 2/2] TEST-06-SELINUX: Disable RuntimeBuildSources= Otherwise fixfiles will try to relabel it which could potentially lead to disaster. We also change the recommendation in HACKING.md to set the default so that TEST-06-SELINUX can override it. --- docs/HACKING.md | 2 +- test/TEST-06-SELINUX/meson.build | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/docs/HACKING.md b/docs/HACKING.md index 5b1e355327..e05f029d90 100644 --- a/docs/HACKING.md +++ b/docs/HACKING.md @@ -52,7 +52,7 @@ image all the time when iterating on a patch, add the following to ```conf [Host] -RuntimeBuildSources=yes +@RuntimeBuildSources=yes ``` After enabling this setting, the source and build directories will be mounted to diff --git a/test/TEST-06-SELINUX/meson.build b/test/TEST-06-SELINUX/meson.build index 5036b64d9a..110b65fbd7 100644 --- a/test/TEST-06-SELINUX/meson.build +++ b/test/TEST-06-SELINUX/meson.build @@ -8,6 +8,9 @@ integration_tests += [ # Use 'auto' to automatically fallback on non-uefi architectures. 'firmware' : 'auto', 'vm' : true, + # Make sure we don't mount anything with virtiofs as otherwise fixfiles will try to relabel + # it. + 'mkosi-args' : integration_test_template['mkosi-args'] + ['--runtime-build-sources=no'], }, ]