-
Notifications
You must be signed in to change notification settings - Fork 12
/
Copy pathMakefile
26 lines (21 loc) · 829 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
COMPILER ?= gcc
#COMPILER ?= clang
NO_VISUAL ?= false
ifeq ($(NO_VISUAL),true)
programs = TextureFiltering TextureStitching
else
programs = Geodesics LineIntegralConvolution TextureFiltering TextureStitching ReactionDiffusion
endif
# Allow "make -j" to operate in parallel over the programs.
all: $(programs)
$(programs):
$(MAKE) -C $@ COMPILER=$(COMPILER) NO_VISUAL=$(NO_VISUAL)
programs_debug = $(foreach n,$(programs),debug_$(n)) # pseudo-dependency to allow "make -j" parallelism
debug: $(programs_debug)
$(programs_debug):
$(MAKE) -C $(@:debug_%:%) debug COMPILER=$(COMPILER)
programs_clean = $(foreach n,$(programs),clean_$(n)) # pseudo-dependency to allow "make -j" parallelism
clean: $(programs_clean)
$(programs_clean):
$(MAKE) -C $(@:clean_%=%) clean
.PHONY: $(programs) $(programs_debug) $(programs_clean)