11 skawarePackages.buildPackage {
12 pname = "s6-linux-init";
14 sha256 = "sha256-Ea4I0KZiELXla2uu4Pa5sbafvtsF/aEoWxFaMcpGx38=";
16 description = "Set of minimalistic tools used to create a s6-based init system, including a /sbin/init binary, on a Linux kernel";
17 platforms = lib.platforms.linux;
27 "--bindir=\${bin}/bin"
28 "--includedir=\${dev}/include"
29 "--with-sysdeps=${skalibs.lib}/lib/skalibs/sysdeps"
30 "--with-include=${skalibs.dev}/include"
31 "--with-include=${execline.dev}/include"
32 "--with-include=${s6.dev}/include"
33 "--with-lib=${skalibs.lib}/lib"
34 "--with-lib=${s6.out}/lib"
35 "--with-lib=${execline.lib}/lib"
36 "--with-dynlib=${skalibs.lib}/lib"
37 "--with-dynlib=${execline.lib}/lib"
38 "--with-dynlib=${s6.out}/lib"
41 # See ../s6-rc/default.nix for an explanation
42 postConfigure = lib.optionalString (stdenv.hostPlatform != stdenv.targetPlatform) ''
43 substituteInPlace src/init/s6-linux-init-maker.c \
44 --replace-fail '<execline/config.h>' '"${targetPackages.execline.dev}/include/execline/config.h"' \
45 --replace-fail '<s6/config.h>' '"${targetPackages.s6.dev}/include/s6/config.h"' \
46 --replace-fail '<s6-linux-init/config.h>' '"${targetPackages.s6-linux-init.dev}/include/s6-linux-init/config.h"'
50 # remove all s6 executables from build directory
51 rm $(find -name "s6-*" -type f -mindepth 1 -maxdepth 1 -executable)
52 rm libs6_linux_init.* libhpr.*
55 mv doc $doc/share/doc/s6-linux-init/html