1 ###############################################################################
2 # Copyright (c) 2000-2014 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 ###############################################################################
9 include ..
/Makefile.regression
11 # WARNING! This Makefile can be used with GNU make only.
12 # Other versions of make may report syntax errors in it.
15 # Do NOT touch this line...
17 .PHONY
: all archive
check clean dep objects
22 # Set these variables...
25 #export LD_LIBRARY_PATH:=$(TTCN3_DIR)/lib:$(LD_LIBRARY_PATH)
28 # Flags for dependency generation
31 # Execution mode: (either ttcn3 or ttcn3-parallel)
32 TTCN3_LIB
= ttcn3
$(RT2_SUFFIX
)-parallel
$(DYNAMIC_SUFFIX
)
36 # You may change these variables. Add your files if necessary...
39 # TTCN-3 modules of this project:
40 TTCN3_MODULES
= no.ttcn
42 # ASN.1 modules of this project:
45 # C++ source & header files generated from the TTCN-3 & ASN.1 modules of
47 GENERATED_SOURCES
= $(TTCN3_MODULES
:.ttcn
=.
cc) $(ASN1_MODULES
:.asn
=.
cc)
48 GENERATED_HEADERS
= $(GENERATED_SOURCES
:.
cc=.hh
)
50 # C/C++ Source & header files of Test Ports, external functions and
53 USER_HEADERS
= $(USER_SOURCES
:.
cc=.hh
)
55 # Object files of this project that are needed for the executable test suite:
56 OBJECTS
= $(GENERATED_OBJECTS
) $(USER_OBJECTS
)
58 GENERATED_OBJECTS
= $(GENERATED_SOURCES
:.
cc=.o
)
60 USER_OBJECTS
= $(USER_SOURCES
:.
cc=.o
)
62 DEPFILES
= $(USER_OBJECTS
:.o
=.d
) $(GENERATED_OBJECTS
:.o
=.d
)
64 # Other files of the project (Makefile, configuration files, etc.)
65 # that will be added to the archived source files:
66 OTHER_FILES
= Makefile logfilecheck
$(wildcard *.cfg
)
68 # The name of the executable test suite:
69 TARGET
= no
$(EXESUFFIX
)
73 # Rules for building the executable...
80 $(TARGET
): $(GENERATED_SOURCES
)
81 $(CXX
) $(CPPFLAGS
) $(CXXFLAGS
) $(LDFLAGS
) -o
$@
$^ \
82 -L
$(TTCN3_DIR
)/lib
-l
$(TTCN3_LIB
) \
83 -L
$(OPENSSL_DIR
)/lib
-lcrypto \
84 -L
$(XMLDIR
)/lib
$($(PLATFORM
)_LIBS
)
87 $(CXX
) -c
$(CPPFLAGS
) $(CXXFLAGS
) -o
$@
$<
90 @echo Creating dependency file for
'$<'; set
-e
; \
91 $(CXX
) $(CXXDEPFLAGS
) $(CPPFLAGS
) $(CXXFLAGS
) $< \
92 | sed
's/\($*\)\.o[ :]*/\1.o $@ : /g' > $@
; \
95 $(GENERATED_SOURCES
) $(GENERATED_HEADERS
): compile
96 @if
[ ! -f
$@
]; then
$(RM
) compile
; $(MAKE
) compile
; fi
98 compile
: $(TTCN3_MODULES
) $(ASN1_MODULES
)
99 $(TTCN3_COMPILER
) $(COMPILER_FLAGS
) $^
- $?
103 -$(RM
) $(TARGET
) $(OBJECTS
) $(GENERATED_HEADERS
) \
104 $(GENERATED_SOURCES
) compile
$(DEPFILES
) \
107 dep
: $(GENERATED_SOURCES
) $(USER_SOURCES
) ;
109 ifeq ($(findstring n
,$(MAKEFLAGS
)),)
110 ifeq ($(filter clean distclean check compile archive diag
,$(MAKECMDGOALS
)),)
117 # Add your rules here if necessary...
121 # clear the field because logging is in append mode
123 $(TTCN3_DIR
)/bin
/ttcn3_start no
$(ABS_SRC
)/config.cfg
-ip
${IP}
124 $(TTCN3_DIR
)/bin
/ttcn3_start no
$(ABS_SRC
)/trouble.cfg
125 $(ABS_SRC
)/logfilecheck