diff options
Diffstat (limited to 'run')
-rwxr-xr-x | run | 15 |
1 files changed, 10 insertions, 5 deletions
@@ -187,8 +187,13 @@ make_build() { $SUDO cp -r disk/* mnt/ $SUDO chmod -R 0 mnt/conf/ $SUDO cp -r build/apps/ mnt/apps/ - $SUDO grub-install --boot-directory=mnt/boot --target=i386-pc --modules="ext2" "$DEV" - $SUDO umount mnt/ || (sleep 1 && sync && sudo umount mnt) + + # Install grub if release + if [ "$MELVIX_CONFIG" = "release" ]; then + $SUDO grub-install --boot-directory=mnt/boot --target=i386-pc --modules="ext2" "$DEV" + fi + + $SUDO umount mnt/ || (sync && sudo umount mnt/) $SUDO rm -rf mnt/ if [ "$(uname -s)" = "OpenBSD" ]; then @@ -202,17 +207,17 @@ make_build() { make_test() { if [ "$mode" = "test" ]; then - qemu_with_flags -serial file:test.log -nographic -drive file=build/disk.img,format=raw,index=1,media=disk + qemu_with_flags -serial file:test.log -nographic -kernel build/apps/kernel/exec -drive file=build/disk.img,format=raw,index=1,media=disk echo grep -E 'PASS|FAIL' test.log if grep -q "All tests passed" test.log; then exit 0; else exit 1; fi else - qemu_with_flags -serial stdio -drive file=build/disk.img,format=raw,index=1,media=disk + qemu_with_flags -serial stdio -kernel build/apps/kernel/exec -drive file=build/disk.img,format=raw,index=1,media=disk fi } make_debug() { - qemu_with_flags -serial stdio -drive file=build/disk.img,format=raw,index=1,media=disk -s -S + qemu_with_flags -serial stdio -kernel build/apps/kernel/exec -drive file=build/disk.img,format=raw,index=1,media=disk -s -S } make_disasm() { |