nix-powerpc/go.sh
2025-02-10 11:47:09 +00:00

14 lines
590 B
Bash
Executable file

# nix build .#pkgsCross.powerpc.ubootNwApp2
# nix build .#pkgsCross.powerpc.nixosConfigurations.ppc.config.boot.kernelPackages.kernel
nix build .#nixosConfigurations.ppc.config.system.build.toplevel --no-eval-cache
ls -l result
sed "s^INIT^$(readlink result)/init^" tftp/boot.txt.tmpl > tftp/boot.txt
mkimage -T script -n 'Boot script' -d tftp/boot.txt tftp/boot.scr
sudo cp result/kernel tftp/uImage
sudo cp result/initrd tftp/initrd
# dtb is fine. i hope
sudo ip addr add 10.0.0.1/24 dev enp5s0u2u2
sudo ip link set enp5s0u2u2 up
sudo dnsmasq -C dnsmasq.conf --tftp-root $(pwd)/tftp -d