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 dbd4e729de
No known key found for this signature in database
5 changed files with 225 additions and 16 deletions

57
glibc/default.nix Normal file
View file

@ -0,0 +1,57 @@
{
fetchurl,
pkgs,
stdenv,
...
}:
let
version = "2.40";
pname = "glibcStandalone";
in
stdenv.mkDerivation (finalAttrs: {
inherit version;
pname = pname;
src = fetchurl {
url = "mirror://gnu/glibc/glibc-${version}.tar.xz";
sha256 = "sha256-GaiQF16SY9dI9ieZPeb0sa+c0h4D8IDkv7Oh+sECBaI=";
};
enableParallelBuilding = true;
configureFlags = [
"--prefix=/"
"--libdir=/lib"
"--bindir=/bin"
"--sysconfdir=/etc"
];
preConfigure =
''
export PWD_P=$(type -tP pwd)
for i in configure io/ftwtest-sh; do
sed -i "$i" -e "s^/bin/pwd^$PWD_P^g"
done
mkdir ../build
cd ../build
configureScript="`pwd`/../$sourceRoot/configure"
'';
nativeBuildInputs = with pkgs; [
bison
python3Minimal
];
outputs = [
"out"
];
preInstall = ''
export DESTDIR=${placeholder "out"}
'';
})