morpheus/mkfile

25 lines
652 B
Makefile
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<config.mk
allpkgs = `{ls pkgs/*}
pkgs = ${allpkgs:pkgs/%=%}
help:VQ:
echo 'Usage: mk <pkg>'
echo '\nTo build all the targets in pkgs/, run `mk world´'
all world:VQ: $pkgs
clean:V:
rm -f .state/* pkgs.mk
# generate a pkgs.mk file with the tarkets for all packages in pkgs/
`{ mkdir -p src }
`{ mkdir -p .state }
`{ echo '# auto-generated file, do not edit' > pkgs.mk }
`{ cd pkgs && for pkg in *; do cat $pkg | sed -e "s,^build:,$pkg:QP./stuff/cmp-pkgs: pkgs/$pkg," >> ../pkgs.mk && echo -e '\tcd $top && cp pkgs/$target .state/$target\n' >> ../pkgs.mk; done }
<pkgs.mk
bootable:V:
stuff/create-bootable "$root" morpheus-$arch-$version.img