Merge github.com:eclipse/titan.core
[deliverable/titan.core.git] / function_test / Makefile
1 ##############################################################################
2 # Copyright (c) 2000-2016 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 # Contributors:
9 # Balasko, Jeno
10 # Baranyi, Botond
11 # Bartha, Norbert
12 # Delic, Adam
13 # Kovacs, Ferenc
14 # Ormandi, Matyas
15 # Raduly, Csaba
16 #
17 ##############################################################################
18 # Makefile to run the non-interactive tests
19 DIRS := BER_EncDec RAW_EncDec Text_EncDec XER_EncDec Semantic_Analyser Semantic_Analyser_Csaba Config_Parser
20
21 SCRIPTFLAGS :=
22
23 # Coverage settings
24 LCOVDIR := /mnt/TTCN/Tools/lcov-1.7/usr
25 LCOV := no
26 ifeq ($(LCOV), yes)
27 SCRIPTFLAGS += -coverage
28 endif
29 # Runtime selection, doesn't have effect on BER/RAW tests yet
30 RT2 := no
31 ifeq ($(RT2), yes)
32 SCRIPTFLAGS += -rt2
33 endif
34
35 # Your platform. Allowed values: SOLARIS, SOLARIS8, LINUX, FREEBSD, WIN32
36 ifndef PLATFORM
37 PLATFORM1 := $(shell uname -s)
38 PLATFORM2 := $(shell uname -r)
39 PLATFORM3 := $(shell uname -m)
40
41 ifeq ($(PLATFORM1), SunOS)
42 ifeq ($(PLATFORM2), 5.6)
43 PLATFORM := SOLARIS
44 else
45 PLATFORM := SOLARIS8
46 endif # 5.6
47 endif # SunOS
48 ifeq ($(PLATFORM1), Linux)
49 PLATFORM := LINUX
50 endif # Linux
51 ifeq ($(PLATFORM1), FreeBSD)
52 PLATFORM := FREEBSD
53 endif # FreeBSD
54 ifeq ($(findstring CYGWIN, $(PLATFORM1)), CYGWIN)
55 PLATFORM := WIN32
56 endif # CYGWIN
57 ifeq ($(PLATFORM1), Interix)
58 PLATFORM := INTERIX
59 endif # Interix
60 endif # ifndef PLATFORM
61 ifndef PLATFORM
62 PLEASE CHECK THE ABOVE PLATFORM SETTINGS!!!
63 endif # ifndef PLATFORM
64
65 export PLATFORM
66
67 all check run: $(DIRS)
68
69 .PHONY: $(DIRS)
70
71 BER_EncDec:
72 cd $@; ./run_test $(SCRIPTFLAGS)
73
74 RAW_EncDec:
75 cd $@; ./run_test $(SCRIPTFLAGS)
76
77 Text_EncDec:
78 cd $@; if [ ! -f perl ] ; then ln -s `which perl` perl; fi; ./run_test $(SCRIPTFLAGS)
79
80 XER_EncDec:
81 cd $@; ./run_test $(SCRIPTFLAGS)
82
83 Semantic_Analyser:
84 cd $@; if [ ! -f perl ] ; then ln -s `which perl` perl; fi; ./run_test_all $(SCRIPTFLAGS)
85
86 Semantic_Analyser_Csaba:
87 make run -f Makefile.semantic -C Semantic_Analyser
88
89 Config_Parser:
90 cd $@; if [ ! -f perl ] ; then ln -s `which perl` perl; fi; ./run_test $(SCRIPTFLAGS)
91
92 profile: $(DIRS)
93 make all
94 $(LCOVDIR)/bin/lcov -d .. -c -o functest_coverage.info
95 $(LCOVDIR)/bin/genhtml -o functest_coverage -t "TITAN Function Test Coverage" functest_coverage.info
96
97 # It's a 50-50
98 clean:
99 for d in $(DIRS); do if [ -f $$d/Makefile ]; then $(MAKE) -C $$d clean; else : ; fi done
100
101 $(CURDIR)/Makefile.personal:
102 ln -s $(CURDIR)/../$(@F) $(CURDIR)/
103 include $(CURDIR)/Makefile.personal
This page took 0.032478 seconds and 5 git commands to generate.