silly uki image with the systemd-ukify tooling

This commit is contained in:
Lars Sjöström 2025-02-17 15:15:24 +01:00
parent 52986e7e70
commit 48b78f93ed
No known key found for this signature in database
2 changed files with 95 additions and 6 deletions

View file

@ -137,9 +137,6 @@ stdenv.mkDerivation (finalAttrs: {
postPatch =
''
substituteInPlace src/basic/path-util.h --replace "@defaultPathNormal@" "${placeholder "out"}/bin/"
''
+ ''
substituteInPlace meson.build \
--replace "find_program('clang'" "find_program('${stdenv.cc.targetPrefix}clang'"
''
@ -150,7 +147,7 @@ stdenv.mkDerivation (finalAttrs: {
"'${targetPackages.stdenv.cc.bintools.targetPrefix}readelf'" \
--replace \
"/usr/lib/systemd/boot/efi" \
"$out/lib/systemd/boot/efi"
"$out/usr/lib/systemd/boot/efi"
''
# Finally, patch shebangs in scripts used at build time. This must not patch
# scripts that will end up in the output, to avoid build platform references
@ -171,7 +168,7 @@ stdenv.mkDerivation (finalAttrs: {
"--sysconfdir=/etc"
"--localstatedir=/var"
"--libdir=/usr/lib"
"--bindir=/bin"
"--bindir=/usr/bin"
"--includedir=/usr/include"
"--localedir=/usr/share/locale"