init version
This commit is contained in:
29
Makefile
Normal file
29
Makefile
Normal file
@@ -0,0 +1,29 @@
|
||||
OUTIMG = oxideos.iso
|
||||
.DEFAULT_GOAL = $(OUTIMG)
|
||||
|
||||
OXIDE_MULTIBOOT = target/target-protected-i386/release/oxide
|
||||
|
||||
RUST_DEP := Cargo.toml Cargo.lock $(shell find .cargo -type f) $(shell find deps -type f)
|
||||
|
||||
KERNELFILE = $(OXIDE_MULTIBOOT)
|
||||
$(KERNELFILE): $(shell find members/oxide -type f) $(RUST_DEP)
|
||||
cargo b -r --target=.cargo/target-protected-i386.json --package oxide
|
||||
|
||||
BOOTLOADER ?= grub
|
||||
include mk/make_bootloader/$(BOOTLOADER).mk
|
||||
|
||||
.PHONY: clean \
|
||||
run-bootloader-qemu run-bootloader-qemu-nographic \
|
||||
run-qemu run-qemu-nographic
|
||||
|
||||
clean: clean-bootloader
|
||||
rm -rf $(OUTIMG) $(FS_IMG) $(MICROLOADER_MBR) $(MICROLOADER_VBA) $(FS_BOOTPART_IMG)
|
||||
run-bootloader-qemu: $(OUTIMG)
|
||||
qemu-system-x86_64 -drive format=raw,file=$(OUTIMG)
|
||||
run-bootloader-qemu-nographic: $(OUTIMG)
|
||||
qemu-system-x86_64 -nographic -drive format=raw,file=$(OUTIMG)
|
||||
# one day qemu will support multiboot2
|
||||
run-qemu: $(KERNELFILE)
|
||||
qemu-system-x86_64 -kernel $(KERNELFILE)
|
||||
run-qemu-nographic: $(KERNELFILE)
|
||||
qemu-system-x86_64 -nographic -kernel $(KERNELFILE)
|
||||
Reference in New Issue
Block a user