1 # Makefile for armsrc, see ../common/Makefile.common for common settings
5 #remove one of the following defines and comment out the relevant line
6 #in the next section to remove that particular feature from compilation
7 APP_CFLAGS
= -O6
-DWITH_LF
-DWITH_ISO15693
-DWITH_ISO14443a
-DWITH_ISO14443b
10 #SRC_LCD = fonts.c LCD.c
11 SRC_LF
= lfops.c hitag2.c
12 SRC_ISO15693
= iso15693.c
13 SRC_ISO14443a
= iso14443a.c
14 SRC_ISO14443b
= iso14443.c
24 # These are to be compiled in ARM mode
25 ARMSRC
= fpgaloader.c \
34 # Do not move this inclusion before the definition of {THUMB,ASM,ARM}SRC
35 include ..
/common
/Makefile.common
37 all: $(OBJDIR
)/osimage.s19
$(OBJDIR
)/fpgaimage.s19
39 $(OBJDIR
)/fpga.o
: fpga.bit
40 $(OBJCOPY
) -O elf32-littlearm
-I binary
-B arm
--redefine-sym _binary____fpga_fpga_bit_start
=_binary_fpga_bit_start
--redefine-sym _binary____fpga_fpga_bit_end
=_binary_fpga_bit_end
--prefix-sections
=fpga_bit
$^
$@
42 $(OBJDIR
)/fullimage.elf
: $(VERSIONOBJ
) $(OBJDIR
)/fpga.o
$(THUMBOBJ
) $(ARMOBJ
) $(LIBGCC
)
43 $(LD
) -g
-Tldscript
-Map
=$(patsubst %.elf
,%.map
,$@
) -o
$@
$^
45 $(OBJDIR
)/fpgaimage.elf
: $(OBJDIR
)/fullimage.elf
46 $(OBJCOPY
) -F elf32-littlearm
--only-section .fpgaimage
$^
$@
48 $(OBJDIR
)/osimage.elf
: $(OBJDIR
)/fullimage.elf
49 $(OBJCOPY
) -F elf32-littlearm
--remove-section .fpgaimage
$^
$@
52 $(DELETE
) $(OBJDIR
)$(PATHSEP
)*.o
53 $(DELETE
) $(OBJDIR
)$(PATHSEP
)*.elf
54 $(DELETE
) $(OBJDIR
)$(PATHSEP
)*.s19
55 $(DELETE
) $(OBJDIR
)$(PATHSEP
)*.map
56 $(DELETE
) $(OBJDIR
)$(PATHSEP
)*.d
59 .PHONY
: all clean help
61 @echo Multi-OS Makefile
, you are running on
$(DETECTED_OS
)
62 @echo Possible targets
:
63 @echo
+ all - Make both
:
64 @echo
+ $(OBJDIR
)/osimage.s19
- The OS image
65 @echo
+ $(OBJDIR
)/fpgaimage.s19
- The FPGA image
66 @echo
+ clean - Clean
$(OBJDIR
)