mini/Makefile

53 lines
1.3 KiB
Makefile
Raw Permalink Normal View History

2009-05-15 14:37:53 +02:00
include starlet.mk
2009-01-07 17:56:57 +01:00
# enabled usbgecko support
CFLAGS += -DCAN_HAZ_USBGECKO
# disables debug spew over usbgecko
#CFLAGS += -DNDEBUG
# enables LFCR linefeeds for usbgecko output, useful for some terminal apps
#CFLAGS += -DGECKO_LFCR
# uses the 'safe' version of the usbgecko receive and send functions
#CFLAGS += -DGECKO_SAFE
2009-04-04 18:59:31 +02:00
ASFLAGS += -D_LANGUAGE_ASSEMBLY
CFLAGS += -DCAN_HAZ_IRQ -DCAN_HAZ_IPC
2009-04-05 16:03:04 +02:00
LDSCRIPT = mini.ld
2009-01-07 17:56:57 +01:00
LIBS = -lgcc
2008-12-28 14:35:37 +01:00
ELFLOADER = elfloader/elfloader.bin
2010-07-12 13:11:32 +02:00
MAKEBIN = $(CURDIR)/makebin.py
2009-01-06 00:13:39 +01:00
2009-04-04 18:59:31 +02:00
TARGET = armboot.elf
TARGET_BIN = armboot.bin
OBJS = start.o main.o ipc.o vsprintf.o string.o gecko.o memory.o memory_asm.o \
utils_asm.o utils.o ff.o diskio.o sdhc.o powerpc_elf.o powerpc.o panic.o \
irq.o irq_asm.o exception.o exception_asm.o seeprom.o crypto.o nand.o \
boot2.o ldhack.o sdmmc.o
2008-12-28 14:35:37 +01:00
2009-05-15 14:37:53 +02:00
include common.mk
2008-12-28 14:35:37 +01:00
2009-04-04 18:59:31 +02:00
all: $(TARGET_BIN)
2008-12-28 14:35:37 +01:00
main.o: main.c git_version.h
2009-04-04 18:59:31 +02:00
$(TARGET_BIN): $(TARGET) $(ELFLOADER)
@echo "MAKEBIN $@"
@$(MAKEBIN) $(ELFLOADER) $< $@
2008-12-28 14:35:37 +01:00
upload: $(TARGET_BIN)
@$(WIIDEV)/bin/bootmii -a $<
2010-07-01 00:48:55 +02:00
git_version.h: describesimple.sh
@echo " GITVER $@"
@echo 'const char git_version[] = "'`./describesimple.sh`'";' > git_version.h
2009-04-04 18:59:31 +02:00
clean: myclean
2008-12-28 14:35:37 +01:00
$(ELFLOADER):
2010-07-01 00:48:55 +02:00
@$(MAKE) -C elfloader
2009-04-04 18:59:31 +02:00
myclean:
-rm -f $(TARGET_BIN) git_version.h
2010-07-01 00:48:55 +02:00
@$(MAKE) -C elfloader clean
2008-12-28 14:35:37 +01:00