]> git.zerfleddert.de Git - proxmark3-svn/blame - armsrc/Makefile
Move most rules to Makefile.common
[proxmark3-svn] / armsrc / Makefile
CommitLineData
7e931bbd 1# Makefile for armsrc, see ../common/Makefile.common for common settings\r
6658905f 2\r
7e931bbd 3APP_INCLUDES = apps.h\r
6658905f 4\r
7e931bbd 5# Add the "-DWITH_LCD" flag in APP_CLFAGS to add support for LCD\r
0fc0fca5 6# and add SRC_LCD to SRC_MAIN\r
7e931bbd 7APP_CFLAGS = -O6\r
6658905f 8\r
0fc0fca5 9SRC_LCD = fonts.c LCD.c\r
10\r
11SRC_MAIN = start.c \\r
12 appmain.c \\r
13 fpga.c \\r
14 lfops.c \\r
15 iso15693.c \\r
16 util.c \\r
17 usb.c\r
18\r
19# These are to be compiled in ARM mode\r
20SRC_MAIN_FAST = iso14443.c \\r
21 iso14443a.c\r
aa4d9d9b 22\r
0fc0fca5 23SRC_FPGA = fpgaimg.c\r
6658905f 24\r
0fc0fca5 25THUMBSRC = $(SRC_MAIN) $(SRC_FPGA)\r
26ARMSRC = $(SRC_MAIN_FAST)\r
27\r
28MAIN_OBJ = $(patsubst %.c,$(OBJDIR)/%.o,$(SRC_MAIN) $(SRC_MAIN_FAST))\r
29\r
30# Do not move this inclusion before the definition of {THUMB,ASM,ARM}{OBJ,SRC}\r
31include ../common/Makefile.common\r
6658905f 32\r
7e931bbd 33all: $(OBJDIR)/osimage.s19 $(OBJDIR)/fpgaimage.s19\r
6658905f 34\r
7e931bbd 35$(OBJDIR)/fpgaimage.elf: $(OBJDIR)/fpgaimg.o\r
36 $(LD) -g -Tldscript-fpga -Map=$(patsubst %.elf,%.map,$@) -o $@ $^\r
6658905f 37\r
0fc0fca5 38$(OBJDIR)/osimage.elf: $(MAIN_OBJ) $(ARMLIB)/libgcc.a\r
7e931bbd 39 $(LD) -g -Tldscript -Map=$(patsubst %.elf,%.map,$@) -o $@ $^\r
6658905f 40\r
6658905f 41clean:\r
7e931bbd 42 $(DELETE) $(OBJDIR)$(PATHSEP)*.o\r
43 $(DELETE) $(OBJDIR)$(PATHSEP)*.elf\r
44 $(DELETE) $(OBJDIR)$(PATHSEP)*.s19\r
45 $(DELETE) $(OBJDIR)$(PATHSEP)*.map\r
0fc0fca5 46 $(DELETE) $(OBJDIR)$(PATHSEP)*.d\r
7e931bbd 47\r
48.PHONY: all clean help\r
49help:\r
50 @echo Multi-OS Makefile, you are running on $(DETECTED_OS)\r
51 @echo Possible targets:\r
52 @echo + all - Make both:\r
53 @echo + osimage.s19 - The OS image\r
54 @echo + fpgaimage.s19 - The FPGA image\r
55 @echo + clean - Clean $(OBJDIR)\r
0fc0fca5 56\r
Impressum, Datenschutz