generate a mips squashfs with some s6-rc services

haven't even tried booting it but I don't expect it to work. Needs

- s6-linux-init or some other pid 1 program
- a kernel
This commit is contained in:
Daniel Barlow
2022-09-19 23:51:38 +01:00
commit 4b118bca19
7 changed files with 223 additions and 0 deletions

16
tools/builder.sh Normal file
View File

@@ -0,0 +1,16 @@
source $stdenv/setup
mkdir -p $out/${name}
echo $type > $out/${name}/type
mkdir -p $out/${name}/dependencies.d
echo $buildInputs > $out/buildInputs
test -n "$dependencies" && for d in "$dependencies"; do
touch $out/${name}/dependencies.d/$d
done
test -n "$contents" && for d in "$contents"; do
mkdir -p $out/${name}/contents.d
touch $out/${name}/contents.d/$d
done
test -n "$run" && (echo "$run" > $out/${name}/run)
test -n "$up" && (echo "$up" > $out/${name}/up)
test -n "$down" && (echo "$down" > $out/${name}/down)
(echo $out/${name} && cd $out/${name} && find . -ls)