File: Makefile

package info (click to toggle)
fastml 3.11-4
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 5,772 kB
  • sloc: cpp: 48,522; perl: 3,588; ansic: 819; makefile: 386; python: 83; sh: 55
file content (36 lines) | stat: -rw-r--r-- 826 bytes parent folder | download | duplicates (5)
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
27
28
29
30
31
32
33
34
35
36
#	$Id: Makefile 11987 2014-01-30 10:23:04Z haim $	

# this split is vital becouse of a bug in make 3.80.1 - see 
# http://www.cygwin.com/ml/cygwin/2004-09/msg01659.html

PROGRAMS1= fastml gainLoss
PROGRAMS2= indelCoder
PROGRAMS = $(PROGRAMS1) $(PROGRAMS2)

# all has to be the FIRST task!
TASKS= all clean test depend debug All install doubleRep
.PHONY: $(TASKS) $(PROGRAMS)

 define TASKS_template1
    $(1): $$(addsuffix .$(1),$(PROGRAMS1))
 endef

 define TASKS_template2
    $(1): $$(addsuffix .$(1),$(PROGRAMS2))
 endef

$(foreach task,$(TASKS),$(eval $(call TASKS_template1,$(task))))
$(foreach task,$(TASKS),$(eval $(call TASKS_template2,$(task))))

define PROGRAM_template
   $(1).%:
	+cd $(1) && make $$(*)
endef

$(foreach prog,$(PROGRAMS),$(eval $(call PROGRAM_template,$(prog))))



$(PROGRAMS):
	+cd $@ && make