Skip to content
This repository was archived by the owner on Jan 22, 2026. It is now read-only.

Commit 44a848a

Browse files
committed
image: don't include osrel section in UKI
1 parent e4e5dad commit 44a848a

2 files changed

Lines changed: 32 additions & 1 deletion

File tree

flake.nix

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,10 @@
2020
system:
2121
let
2222
overlay = final: prev: {
23+
mkosi = prev.mkosi.overrideAttrs (old: {
24+
patches = old.patches or [ ] ++ [ ./image/0001-drop-.osrel-UKI-section.patch ];
25+
});
26+
2327
rpm = prev.rpm.overrideAttrs (old: {
2428
nativeBuildInputs = old.nativeBuildInputs ++ [ prev.makeWrapper ];
2529
postFixup = ''
@@ -94,7 +98,8 @@
9498
# Note that it's *not* a legacy attribute.
9599
legacyPackages = {
96100
generate = pkgs.callPackage ./nix/generate.nix { };
97-
} // pkgs;
101+
}
102+
// pkgs;
98103

99104
packages.mkosi = mkosiDev;
100105

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
From d1f8df825632c244e4c087c7be83abe37d9ff9a6 Mon Sep 17 00:00:00 2001
2+
From: Moritz Sanft <[email protected]>
3+
Date: Fri, 29 Aug 2025 17:06:48 +0200
4+
Subject: [PATCH] drop .osrel UKI section
5+
6+
Signed-off-by: Moritz Sanft <[email protected]>
7+
---
8+
mkosi/__init__.py | 2 +-
9+
1 file changed, 1 insertion(+), 1 deletion(-)
10+
11+
diff --git a/mkosi/__init__.py b/mkosi/__init__.py
12+
index 65cac772..0266a595 100644
13+
--- a/mkosi/__init__.py
14+
+++ b/mkosi/__init__.py
15+
@@ -1706,7 +1706,7 @@ def build_uki(
16+
json_out = False
17+
18+
arguments: list[PathString] = [
19+
- "--os-release", f"@{workdir(context.root / 'usr/lib/os-release')}",
20+
+ # "--os-release", f"@{workdir(context.root / 'usr/lib/os-release')}",
21+
"--uname", kver,
22+
"--linux", workdir(kimg),
23+
*flatten(["--join-profile", os.fspath(workdir(profile))] for profile in profiles),
24+
--
25+
2.51.0
26+

0 commit comments

Comments
 (0)