When we read the year from the RTC, it can be so totally messed up so that
[kugel-rb.git] / gdb / Makefile
blob21c0cf83419b0b762de902289fe26a5b5c5b960e
1 # __________ __ ___.
2 # Open \______ \ ____ ____ | | _\_ |__ _______ ___
3 # Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
4 # Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
5 # Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
6 # \/ \/ \/ \/ \/
7 # $Id$
10 ifdef RECORDER
11 EXTRA = -DRECORDER
12 EXT = ajz
13 else
14 EXT = mod
15 endif
17 TARGET = stub
18 OBJS = start.o sh-stub.o setjmp.o
19 LIBS = -lgcc
21 .s.o:
22 sh-elf-as -o $@ $<
24 .c.o:
25 sh-elf-gcc -O $(EXTRA) -I../firmware/export -I../firmware/include -m1 -Wall -Wstrict-prototypes -c -o $@ $<
27 .S.o:
28 sh-elf-gcc -O -I../firmware/export -I../firmware/include -m1 -Wall -Wstrict-prototypes -c -o $@ $<
30 $(TARGET).$(EXT): $(TARGET).elf
31 sh-elf-objcopy -O binary $(TARGET).elf $(TARGET).out
32 ../tools/scramble $(TARGET).out $(TARGET).$(EXT)
34 $(TARGET).elf: $(OBJS)
35 sh-elf-gcc -nostartfiles $(OBJS) -nostdlib -Wl,-Map,$(TARGET).map -o $(TARGET).elf -Tlinker.cfg
37 clean:
38 rm $(OBJS) $(TARGET).map $(TARGET).elf $(TARGET).out $(TARGET).mod $(TARGET).ajz
40 start.o: start.s
41 sh-stub.o: sh-stub.c
42 setjmp.o: setjmp.S