diff --git a/.gitignore b/.gitignore index 6833589..8cfe0d4 100644 --- a/.gitignore +++ b/.gitignore @@ -5,7 +5,8 @@ /result /target /out -/initrd.gz +/initrd* +/patos* .*.swp .*.swo .nixos-test-history diff --git a/flake.nix b/flake.nix index 90fe634..9e95404 100644 --- a/flake.nix +++ b/flake.nix @@ -28,7 +28,7 @@ mkdir -p patos/efi/boot ${self.packages.${system}.systemd.out}/usr/bin/ukify build \ --linux ${self.packages.${system}.kernel.kernel}/bzImage \ - --initrd ./initrd.gz \ + --initrd ./initrd.xz \ --cmdline "console=ttyS0" \ -o patos/efi/boot/bootx64.efi ''; diff --git a/systemd/0017-meson.build-do-not-create-systemdstatedir.patch b/systemd/0017-meson.build-do-not-create-systemdstatedir.patch deleted file mode 100644 index debcaab..0000000 --- a/systemd/0017-meson.build-do-not-create-systemdstatedir.patch +++ /dev/null @@ -1,21 +0,0 @@ -From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 -From: nikstur -Date: Mon, 6 Nov 2023 22:51:38 +0100 -Subject: [PATCH] meson.build: do not create systemdstatedir - ---- - meson.build | 1 - - 1 file changed, 1 deletion(-) - -diff --git a/meson.build b/meson.build -index bffda86845..cb5dcec0f9 100644 ---- a/meson.build -+++ b/meson.build -@@ -2781,7 +2781,6 @@ install_data('LICENSE.GPL2', - install_subdir('LICENSES', - install_dir : docdir) - --install_emptydir(systemdstatedir) - - ##################################################################### - diff --git a/systemd/default.nix b/systemd/default.nix index 3174f0f..4daf9ed 100644 --- a/systemd/default.nix +++ b/systemd/default.nix @@ -32,10 +32,6 @@ stdenv.mkDerivation (finalAttrs: { dontCheckForBrokenSymlinks = true; - patches = [ - ./0017-meson.build-do-not-create-systemdstatedir.patch - ]; - nativeBuildInputs = with pkgs; [ bash pkg-config @@ -196,7 +192,7 @@ stdenv.mkDerivation (finalAttrs: { (lib.mesonOption "dbussystemservicedir" "/usr/share/dbus-1/system-services") (lib.mesonOption "setfont-path" "/usr/bin/setfont") (lib.mesonOption "loadkeys-path" "/usr/bin/loadkeys") - (lib.mesonOption "sulogin-path" "/usr/bin/sulogin") + (lib.mesonOption "sulogin-path" "/usr/bin/sulogin") (lib.mesonOption "nologin-path" "/usr/bin/nologin") (lib.mesonOption "mount-path" "/usr/bin/mount") (lib.mesonOption "umount-path" "/usr/bin/umount") diff --git a/utils/mkinitrd.nix b/utils/mkinitrd.nix index 47f7f30..201d14c 100644 --- a/utils/mkinitrd.nix +++ b/utils/mkinitrd.nix @@ -8,7 +8,7 @@ pkgs.writeShellApplication { runtimeInputs = with pkgs; [ cpio - gzip + xz ]; text = '' @@ -117,7 +117,7 @@ pkgs.writeShellApplication { ln -sf ../demo.service usr/lib/systemd/system/basic.target.wants/demo.service # gen initrd - find . -print0 | cpio --null --owner=root:root -o --format=newc | gzip -9 > ../initrd.gz + find . -print0 | cpio --null --owner=root:root -o --format=newc | xz -9 --check=crc32 > ../initrd.xz popd rm -rf root