]> git.ipfire.org Git - thirdparty/mkosi.git/commitdiff
Search for underscores in `systemd-stub`
authorRussell Bunch <rusty@4lambda.io>
Tue, 18 Feb 2025 16:58:52 +0000 (10:58 -0600)
committerDaan De Meyer <daan.j.demeyer@gmail.com>
Tue, 18 Feb 2025 17:52:08 +0000 (18:52 +0100)
Building raw disk images of RHEL 9 x86-64 are failing with:
```
...‣ Unable to determine systemd-stub version, found '#### LoaderInfo: systemd-stub 252-46.el9_5.2 ####'
```

Changes the regex for `systemd-stub` to include underscores for RHEL95.

mkosi/__init__.py

index d01baf64402ae9f8b768ced2caadc7e7ab68ba3e..aca3ef558ea97a6958f9e01197016835bc9d34ff 100644 (file)
@@ -1849,7 +1849,7 @@ def systemd_stub_version(context: Context, stub: Path) -> Optional[GenericVersio
 
     if not (
         version := re.match(
-            r"#### LoaderInfo: systemd-stub (?P<version>[.~^a-zA-Z0-9-+]+) ####", sdmagic_text
+            r"#### LoaderInfo: systemd-stub (?P<version>[.~^a-zA-Z0-9-+_]+) ####", sdmagic_text
         )
     ):
         die(f"Unable to determine systemd-stub version, found {sdmagic_text!r}")