Revision 6ac03b0f Target/Makefile

View differences:

Target/Makefile
24 24

  
25 25

  
26 26

  
27
ROOT_PATH = ..
28
DWD11_PATH = $(ROOT_PATH)/Target/Modules/DiWheelDrive_1-1/Boot
29
PM11_PATH = $(ROOT_PATH)/Target/Modules/PowerManagement_1-1/Boot
30
LR10_PATH = $(ROOT_PATH)/Target/Modules/LightRing_1-0/Boot
27
TARGET_PATH = $(dir $(abspath $(lastword $(MAKEFILE_LIST))))
28
MODULES = $(patsubst $(TARGET_PATH)Modules/%/,%,$(sort $(dir $(wildcard $(TARGET_PATH)Modules/*/*))))
31 29

  
32
all:
33
	$(MAKE) -C $(DWD11_PATH)
34
	$(MAKE) -C $(PM11_PATH)
35
	$(MAKE) -C $(LR10_PATH)
30
CLEANTRGS = $(MODULES:%=clean_%)
31
FLASHTRGS = $(MODULES:%=flash_%)
36 32

  
37
clean:
38
	$(MAKE) -C $(DWD11_PATH) clean
39
	$(MAKE) -C $(PM11_PATH) clean
40
	$(MAKE) -C $(LR10_PATH) clean
33
all: $(MODULES)
41 34

  
42
DiWheelDrive_1-1:
43
	$(MAKE) -C $(DWD11_PATH)
35
$(MODULES):
36
	$(MAKE) -C $(TARGET_PATH)Modules/$@/Boot/
44 37

  
45
PowerManagement_1-1:
46
	$(MAKE) -C $(PM11_PATH)
38
clean: $(CLEANTRGS)
47 39

  
48
LightRing_1-0:
49
	$(MAKE) -C $(LR10_PATH)
40
$(CLEANTRGS):
41
	$(MAKE) -C $(TARGET_PATH)Modules/$(@:clean_%=%)/Boot/ clean
50 42

  
51
flash_DiWheelDrive_1-1:
52
	$(MAKE) -C $(DWD11_PATH) flash
53

  
54
flash_PowerManagement_1-1:
55
	$(MAKE) -C $(PM11_PATH) flash
56

  
57
flash_LightRing_1-0:
58
	$(MAKE) -C $(LR10_PATH) flash
43
$(FLASHTRGS): $(@:flash_%=%)
44
	$(MAKE) -C $(TARGET_PATH)Modules/$(@:flash_%=%)/Boot/ flash
59 45

  

Also available in: Unified diff