Commit | Line | Data |
---|---|---|
d44e3c4f | 1 | ############################################################################## |
2 | # Copyright (c) 2000-2016 Ericsson Telecom AB | |
970ed795 EL |
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 | |
d44e3c4f | 7 | # |
8 | # Contributors: | |
9 | # Balasko, Jeno | |
10 | # Baranyi, Botond | |
11 | # Lovassy, Arpad | |
12 | # Szabados, Kristof | |
13 | # | |
14 | ############################################################################## | |
970ed795 EL |
15 | # This Makefile was generated by the compiler |
16 | # of the TTCN-3 Test Executor version 1.5.pl1 | |
17 | # for Botond Baranyi (ebotbar) on Tue Apr 29 13:50:16 2014 | |
18 | ||
19 | # The following make commands are available: | |
20 | # - make, make all Builds the executable test suite. | |
21 | # - make compile Translates TTCN-3 and ASN.1 modules to C++. | |
22 | # - make clean Removes all generated files. | |
23 | # - make dep Creates/updates dependency list. | |
24 | # - make archive Archives all source files. | |
25 | ||
26 | # | |
27 | # Set these variables... | |
28 | # | |
29 | ||
3abe9331 | 30 | TOP := ../../ |
31 | include $(TOP)/Makefile.cfg | |
32 | ||
33 | ||
970ed795 EL |
34 | # The path of your TTCN-3 Test Executor installation: |
35 | # Uncomment this line to override the environment variable. | |
36 | # TTCN3_DIR = | |
37 | ||
38 | # Your platform: (SOLARIS, LINUX, FREEBSD or WIN32) | |
39 | ifndef PLATFORM | |
40 | PLATFORM = SOLARIS | |
41 | endif | |
42 | ||
43 | # Your C++ compiler: | |
01fb194f | 44 | #CXX = g++ |
970ed795 | 45 | |
970ed795 EL |
46 | # Flags for the C++ preprocessor (and makedepend as well): |
47 | CPPFLAGS = -D$(PLATFORM) -I$(TTCN3_DIR)/include -I$(XMLDIR)/include/libxml2 | |
48 | ifdef RT2 | |
49 | CPPFLAGS += -DTITAN_RUNTIME_2 | |
50 | endif | |
51 | ||
52 | # Flags for the C++ compiler: | |
53 | CXXFLAGS = -Wall | |
54 | ||
55 | # Flags for the linker: | |
56 | LDFLAGS = | |
57 | ||
58 | # Flags for the TTCN-3 and ASN.1 compiler: | |
59 | COMPILER_FLAGS = -L | |
60 | ifdef RT2 | |
61 | COMPILER_FLAGS += -R | |
62 | endif | |
63 | ||
64 | # Execution mode: (either ttcn3 or ttcn3-parallel) | |
65 | ifndef RT2 | |
66 | TTCN3_LIB = ttcn3 | |
67 | else | |
68 | TTCN3_LIB = ttcn3-rt2 | |
69 | endif | |
70 | ||
71 | # The path of your OpenSSL installation: | |
72 | # If you do not have your own one, leave it unchanged. | |
73 | OPENSSL_DIR = $(TTCN3_DIR) | |
74 | ||
75 | # Directory to store the archived source files: | |
76 | # Note: you can set any directory except ./archive | |
77 | ARCHIVE_DIR = ./backup | |
78 | ||
79 | # | |
80 | # You may change these variables. Add your files if necessary... | |
81 | # | |
82 | ||
83 | # The TTCN-3 modules needed for this project: | |
84 | TTCN3_MODULES = Temp.ttcn | |
85 | ||
86 | # The ASN.1 modules needed for this project: | |
87 | ASN1_MODULES = | |
88 | ||
89 | # C++ source & header files generated by TTCN-3 & ASN.1 compilers: | |
90 | GENERATED_SOURCES = Temp.cc | |
91 | GENERATED_HEADERS = Temp.hh | |
92 | ||
93 | # Source & header files of Test Ports and your other modules: | |
94 | USER_SOURCES = | |
95 | USER_HEADERS = | |
96 | ||
97 | # All object files needed for the executable test suite: | |
98 | OBJECTS = Temp.o | |
99 | ||
100 | # The name of the executable test suite: | |
101 | TARGET = Temp | |
102 | ||
103 | ifdef COVERAGE | |
3abe9331 | 104 | CPPFLAGS += -fprofile-arcs -ftest-coverage -g |
970ed795 EL |
105 | CXXFLAGS += -fprofile-arcs -ftest-coverage -g |
106 | LDFLAGS += -fprofile-arcs -ftest-coverage -g -lgcov | |
107 | endif | |
108 | ||
109 | # | |
110 | # Do not modify these unless you know what you are doing... | |
111 | # | |
f08ff9ca BB |
112 | SOLARIS_LIBS = -lxnet -L$(XMLDIR)/lib -lxml2 -lcurses |
113 | SOLARIS8_LIBS = -lxnet -L$(XMLDIR)/lib -lxml2 -lnsl -lsocket -lresolv -lcurses | |
114 | LINUX_LIBS = -L$(XMLDIR)/lib -lxml2 -lpthread -lrt -lncurses | |
115 | FREEBSD_LIBS = -L$(XMLDIR)/lib -lxml2 -lncurses | |
116 | WIN32_LIBS = -L$(XMLDIR)/lib -lxml2 -lncurses | |
970ed795 EL |
117 | |
118 | # | |
119 | # Rules for building the executable... | |
120 | # | |
121 | all: $(TARGET) ; | |
122 | ||
123 | $(TARGET): $(OBJECTS) | |
124 | $(CXX) $(LDFLAGS) -o $@ $(OBJECTS) -L$(TTCN3_DIR)/lib -l$(TTCN3_LIB) \ | |
125 | -L$(OPENSSL_DIR)/lib -lcrypto $($(PLATFORM)_LIBS) | |
126 | ||
127 | .cc.o .c.o: | |
128 | $(CXX) -c $(CPPFLAGS) $(CXXFLAGS) $< | |
129 | ||
130 | $(GENERATED_SOURCES) $(GENERATED_HEADERS): compile | |
131 | @if [ ! -f $@ ]; then $(RM) compile; $(MAKE) compile; fi | |
132 | ||
133 | compile: $(TTCN3_MODULES) $(ASN1_MODULES) | |
134 | $(TTCN3_DIR)/bin/compiler $(COMPILER_FLAGS) $(TTCN3_MODULES) \ | |
135 | $(ASN1_MODULES) - $? | |
136 | touch $@ | |
137 | ||
138 | clean: | |
139 | -$(RM) $(TARGET) $(OBJECTS) $(GENERATED_HEADERS) \ | |
140 | $(GENERATED_SOURCES) compile *.log *.gcda *.gcno | |
141 | ||
142 | dep: $(GENERATED_SOURCES) | |
143 | makedepend $(CPPFLAGS) $(USER_SOURCES) $(GENERATED_SOURCES) | |
144 | ||
145 | archive: | |
146 | mkdir -p $(ARCHIVE_DIR) | |
147 | tar -cvhf - $(TTCN3_MODULES) $(ASN1_MODULES) \ | |
148 | $(USER_HEADERS) $(USER_SOURCES) Makefile \ | |
149 | | gzip >$(ARCHIVE_DIR)/$(TARGET)-`date '+%y%m%d-%H%M'`.tgz | |
150 | ||
151 | # | |
152 | # Add your rules here if necessary... | |
153 | # |