]> git.zerfleddert.de Git - proxmark3-svn/blame - Makefile
change usb_cmd struct to be more sane
[proxmark3-svn] / Makefile
CommitLineData
db335b3d 1include common/Makefile.common
2
3ifeq ($(DETECTED_OS),Linux)
4HOST_BINARY=linux
5else
6HOST_BINARY=winsrc
7endif
8
64b81198 9all clean: %: bootrom/% armsrc/% $(HOST_BINARY)/%
db335b3d 10
64b81198 11bootrom/%: FORCE
12 $(MAKE) -C bootrom $(patsubst bootrom/%,%,$@)
13armsrc/%: FORCE
14 $(MAKE) -C armsrc $(patsubst armsrc/%,%,$@)
15linux/%: FORCE
16 $(MAKE) -C linux $(patsubst linux/%,%,$@)
17winsrc/%: FORCE
18 $(MAKE) -C winsrc $(patsubst winsrc/%,%,$@)
19FORCE: # Dummy target to force remake in the subdirectories, even if files exist (this Makefile doesn't know about the prerequisites)
20
21
22.PHONY: all clean help _test flash-bootrom flash-os flash-both flash-all FORCE
db335b3d 23help:
24 @echo Multi-OS Makefile, you are running on $(DETECTED_OS)
25 @echo Possible targets:
64b81198 26 @echo + all - Make bootrom, armsrc and the OS-specific host directory
27 @echo + flash-bootrom - Make bootrom and flash it
28 @echo + flash-os - Make armsrc and flash os
29 @echo + flash-both - Make armsrc and flash os and fpga image
30 @echo + flash-all - Make bootrom and armsrc and flash bootrom, os and fpga image
31 @echo + clean - Clean in bootrom, armsrc and the OS-specific host directory
32
33flash-bootrom: bootrom/obj/bootrom.s19 $(FLASH_TOOL)
34 $(FLASH_TOOL) bootrom $(subst /,$(PATHSEP),$<)
35
36flash-os: armsrc/obj/osimage.s19 $(FLASH_TOOL)
37 $(FLASH_TOOL) os $(subst /,$(PATHSEP),$<)
38
39flash-both: armsrc/obj/osimage.s19 armsrc/obj/fpgaimage.s19 $(FLASH_TOOL)
40 $(FLASH_TOOL) os,fpga $(subst /,$(PATHSEP),$(filter-out $(FLASH_TOOL),$^))
41
42flash-all: bootrom/obj/bootrom.s19 armsrc/obj/osimage.s19 armsrc/obj/fpgaimage.s19 $(FLASH_TOOL)
43 $(FLASH_TOOL) bootrom,os,fpga $(subst /,$(PATHSEP),$(filter-out $(FLASH_TOOL),$^))
52b3d184 44
45# Dummy target to test for GNU make availability
46_test:
Impressum, Datenschutz