aboutsummaryrefslogtreecommitdiff
path: root/run
diff options
context:
space:
mode:
authorMarvin Borner2020-06-17 18:31:46 +0200
committerMarvin Borner2020-06-17 18:31:46 +0200
commiteed77bd2970a00d1394ed027ceca5b646e4671ce (patch)
treec44643d98aed2b6818f2b33417c0dea9c5853094 /run
parent49dfa1f4021026bf7c4d77817959c8aa24067016 (diff)
Started rewrite
Diffstat (limited to 'run')
-rwxr-xr-xrun43
1 files changed, 13 insertions, 30 deletions
diff --git a/run b/run
index 974bfa9..b7f860b 100755
--- a/run
+++ b/run
@@ -89,49 +89,32 @@ make_cross() {
}
make_build() {
- mkdir -p iso/
+ mkdir -p build/ disk/bin/
echo "Building..."
- mkdir -p build/kernel/
- mkdir -p build/res/
- mkdir -p build/user/
cd build/
cmake .. >/dev/null
make
cd ..
- # Create ISO
- mkdir -p ./iso/boot/grub/
- cp ./build/kernel/kernel.bin ./iso/boot/kernel.bin
- cp ./src/bootloader/grub.cfg ./iso/boot/grub/
- grub-mkrescue -o ./build/melvix.iso ./iso/
-
- # Check ISO
- if grub-file --is-x86-multiboot2 ./build/kernel/kernel.bin; then
- echo "Multiboot confirmed"
- else
- echo "Kernel is corrupted!"
- exit 1
- fi
-
# Create disk image
- make_genext2fs
- mkdir ./mnt/
- mkdir -p ./mnt/etc/
- mkdir -p ./mnt/usr/
- mkdir -p ./mnt/bin/
-
- cp ./build/res/font.bin ./mnt/bin/font
- cp ./build/user/* ./mnt/bin/
- echo "Hello world, ext2!" | tee -a ./mnt/etc/test
- /usr/local/bin/genext2fs -B 4096 -d mnt -U -N 4096 -b 65536 ./build/disk.img
- rm -r mnt/
+ # make_genext2fs
+ # mkdir ./mnt/
+ # mkdir -p ./mnt/etc/
+ # mkdir -p ./mnt/usr/
+ # mkdir -p ./mnt/bin/
+
+ # cp ./build/res/font.bin ./mnt/bin/font
+ # cp ./build/user/* ./mnt/bin/
+ # echo "Hello world, ext2!" | tee -a ./mnt/etc/test
+ # /usr/local/bin/genext2fs -B 4096 -d mnt -U -N 4096 -b 65536 ./build/disk.img
+ # rm -r mnt/
printf "Build finshed successfully!\n\n"
}
make_test() {
- qemu_with_flags -cdrom ./build/melvix.iso -hda ./build/disk.img
+ qemu_with_flags -cdrom ./build/melvix.iso# -hda ./build/disk.img
}
make_debug() {