1 |
# Truck Computer Dooom! |
2 |
# |
3 |
# Douglas Thrift |
4 |
# |
5 |
# $Id$ |
6 |
|
7 |
common := Common |
8 |
|
9 |
include $(common)/common.mk |
10 |
|
11 |
targets := $(common) Audacious DashInterface GPS Music SteeringWheelRemote |
12 |
all := $(patsubst %, all-%, $(targets)) |
13 |
clean := $(patsubst %, clean-%, $(targets)) |
14 |
|
15 |
.PHONY: all $(all) clean $(clean) |
16 |
|
17 |
all: $(all) |
18 |
|
19 |
define all-target |
20 |
all-$(1): |
21 |
$(call recurse,$(1)) |
22 |
endef |
23 |
|
24 |
$(foreach target,$(targets),$(eval $(call all-target,$(target)))) |
25 |
|
26 |
all-DashInterface: all-Common all-Audacious all-GPS all-Music |
27 |
|
28 |
all-Music: all-Common |
29 |
|
30 |
all-SteeringWheelRemote: all-Common all-Audacious |
31 |
|
32 |
clean: $(clean) |
33 |
|
34 |
define clean-target |
35 |
clean-$(1): |
36 |
$(call recurse,$(1),clean) |
37 |
endef |
38 |
|
39 |
$(foreach target,$(targets),$(eval $(call clean-target,$(target)))) |