Sync with 5.4.0
[deliverable/titan.core.git] / regression_test / lazyEval / Makefile
1 ###############################################################################
2 # Copyright (c) 2000-2015 Ericsson Telecom AB
3 # All rights reserved. This program and the accompanying materials
4 # are made available under the terms of the Eclipse Public License v1.0
5 # which accompanies this distribution, and is available at
6 # http://www.eclipse.org/legal/epl-v10.html
7 ###############################################################################
8 TOPDIR := ../
9 include $(TOPDIR)/Makefile.regression
10
11 MAKE_PROG := $(MAKE)
12
13 TTCN_FILE := lazy_main.ttcn
14 TTCN_FILES := lazy_main.ttcn lazy_A.ttcn lazy_B.ttcn lazy_defs.ttcn LazyASNTypes.asn
15 CFG := lazy.cfg
16
17 FILES := $(TTCN_FILES) $(CFG)
18
19 RUNNABLE := $(TTCN_FILE:.ttcn=)
20
21 #ifeq ($(PLATFORM), WIN32)
22 #RUNNABLE += .exe
23 #endif
24
25 COVERAGE_FLAG :=
26 ifeq ($(COVERAGE), yes)
27 COVERAGE_FLAG += -C
28 endif
29
30 DIR_SINGLE := dir_single_mode
31 DIR_PARALLEL := dir_parallel_mode
32 GENERATED_DIRS := $(DIR_SINGLE) $(DIR_PARALLEL)
33
34 # List of fake targets:
35 .PHONY: all clean run run_single run_parallel runall
36
37 all: $(GENERATED_DIRS)
38
39 $(DIR_SINGLE):
40 mkdir $@
41 cd $@ && for file in $(FILES); do ln -s ../$$file || exit; done
42 cd $@ && $(TTCN3_DIR)/bin/ttcn3_makefilegen $(COVERAGE_FLAG) -s -e $(RUNNABLE) ./* && $(MAKE_PROG)
43
44 $(DIR_PARALLEL):
45 mkdir $@
46 cd $@ && for file in $(FILES); do ln -s ../$$file || exit; done
47 cd $@ && $(TTCN3_DIR)/bin/ttcn3_makefilegen $(COVERAGE_FLAG) -e $(RUNNABLE) ./* && $(MAKE_PROG)
48
49 run: $(GENERATED_DIRS)
50 cd $(DIR_SINGLE) && ./$(RUNNABLE) $(CFG) && grep "Overall verdict: pass" *.log
51 cd $(DIR_PARALLEL) && $(TTCN3_DIR)/bin/ttcn3_start $(RUNNABLE) $(CFG) && grep "Overall verdict: pass" *.log
52
53 # To run all tests, possibly in parallel
54 run_single: $(DIR_SINGLE)
55 cd $(DIR_SINGLE) && ./$(RUNNABLE) $(CFG) && grep "Overall verdict: pass" *.log
56
57 run_parallel: $(DIR_PARALLEL)
58 cd $(DIR_PARALLEL) && $(TTCN3_DIR)/bin/ttcn3_start $(RUNNABLE) $(CFG) && grep "Overall verdict: pass" *.log
59
60 runall: run_single run_parallel
61
62 clean distclean:
63 rm -rf $(GENERATED_DIRS)
64
This page took 0.04944 seconds and 5 git commands to generate.