X-Git-Url: http://git.mutantstargoat.com/user/nuclear/?p=rpikern;a=blobdiff_plain;f=Makefile;h=24a3fb6eeaa577d4380135ed6d24df8c905e3125;hp=739bfddcaba376b89f3b929c2f50c537e6fa8bfa;hb=32ccc707bc0821d7ff4248fe9f58e92e9c6ebef9;hpb=e3851fa5fc01560a8ab799046b7cf0d2f35f18e8 diff --git a/Makefile b/Makefile index 739bfdd..24a3fb6 100644 --- a/Makefile +++ b/Makefile @@ -17,15 +17,16 @@ endif warn = -pedantic -Wall dbg = -g -inc = -Isrc/libc -gccopt = -fpic -ffreestanding -nostdinc -arch = -mcpu=arm1176jzf-s +inc = -Isrc -Isrc/libc +gccopt = -marm -fpic -ffreestanding -nostdinc -ffast-math -fno-math-errno +#arch = -mcpu=arm1176jzf-s +arch = -mcpu=cortex-a7 CFLAGS = $(arch) $(warn) $(opt) $(dbg) $(gccopt) $(inc) $(def) ASFLAGS = $(arch) $(dbg) $(inc) LDFLAGS = -nostdlib -T rpikern.ld -print-gc-sections -QEMU_FLAGS = -m 256 -M raspi2 -serial stdio +QEMU_FLAGS = -m 1024 -M raspi2 -serial stdio -d guest_errors $(bin): $(elf) @@ -48,6 +49,14 @@ clean: cleandep: rm -f $(dep) -.PHONY: debug -debug: $(elf) +.PHONY: run +run: $(elf) qemu-system-arm $(QEMU_FLAGS) -kernel $(elf) + +.PHONY: disasm +disasm: $(elf) + $(toolprefix)objdump -d $< + +.PHONY: install +install: $(bin) + cp $(bin) /srv/tftp/$(bin)