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 ###############################################################################
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 # Flags for dependency generation
28 ifeq ($(PLATFORM
), WIN32
)
29 # Silence linker warnings.
30 # Overridden by Makefile.cfg
33 # Flags for the TTCN-3 and ASN.1 compiler:
36 # Execution mode: (either ttcn3 or ttcn3-parallel)
37 TTCN3_LIB
= ttcn3
$(RT2_SUFFIX
)$(DYNAMIC_SUFFIX
)
41 # You may change these variables. Add your files if necessary...
44 # TTCN-3 modules of this project:
45 TTCN3_MODULES
= General_Types.ttcn SGsAP_Types.ttcn HN25015.ttcn
47 # ASN.1 modules of this project:
50 # C++ source & header files generated from the TTCN-3 & ASN.1 modules of
52 GENERATED_SOURCES
= $(TTCN3_MODULES
:.ttcn
=.
cc) $(ASN1_MODULES
:.asn
=.
cc)
53 GENERATED_HEADERS
= $(GENERATED_SOURCES
:.
cc=.hh
)
55 # C/C++ Source & header files of Test Ports, external functions and
58 USER_HEADERS
= $(USER_SOURCES
:.
cc=.hh
)
60 # Object files of this project that are needed for the executable test suite:
61 OBJECTS
= $(GENERATED_OBJECTS
) $(USER_OBJECTS
)
63 GENERATED_OBJECTS
= $(GENERATED_SOURCES
:.
cc=.o
)
65 USER_OBJECTS
= $(USER_SOURCES
:.
cc=.o
)
67 DEPFILES
= $(USER_OBJECTS
:.o
=.d
) $(GENERATED_OBJECTS
:.o
=.d
)
70 # The name of the executable test suite:
71 TARGET
= HN25015
$(RT2_SUFFIX
)$(EXESUFFIX
)
74 # Rules for building the executable...
82 if
$(CXX
) $(LDFLAGS
) -o
$@
$^ \
83 -L
$(TTCN3_DIR
)/lib
-l
$(TTCN3_LIB
) \
84 -L
$(OPENSSL_DIR
)/lib
-lcrypto \
85 -L
$(XMLDIR
)/lib
$($(PLATFORM
)_LIBS
); \
86 then
: ; else $(TTCN3_DIR
)/bin
/titanver
$(OBJECTS
); exit
1; fi
89 $(CXX
) -c
$(CPPFLAGS
) $(CXXFLAGS
) -o
$@
$<
92 @echo Creating dependency file for
'$<'; set
-e
; \
93 $(CXX
) $(CXXDEPFLAGS
) $(CPPFLAGS
) $(CXXFLAGS
) $< \
94 | sed
's/\($*\)\.o[ :]*/\1.o $@ : /g' > $@
; \
97 $(GENERATED_SOURCES
) $(GENERATED_HEADERS
): compile
98 @if
[ ! -f
$@
]; then
$(RM
) compile
; $(MAKE
) compile
; fi
100 compile
: $(TTCN3_MODULES
) $(ASN1_MODULES
)
101 $(TTCN3_COMPILER
) $(COMPILER_FLAGS
) $^
- $?
106 -$(RM
) $(TARGET
) $(OBJECTS
) $(GENERATED_HEADERS
) \
107 $(GENERATED_SOURCES
) compile
$(DEPFILES
) \
114 dep
: $(GENERATED_SOURCES
) $(USER_SOURCES
) ;
116 ifeq ($(findstring n
,$(MAKEFLAGS
)),)
117 ifeq ($(filter clean distclean check compile archive diag
,$(MAKECMDGOALS
)),)
125 $(TTCN3_COMPILER
) -v
2>&1
126 $(TTCN3_DIR
)/bin
/mctr_cli
-v
2>&1
128 @echo TTCN3_DIR
=$(TTCN3_DIR
)
129 @echo OPENSSL_DIR
=$(OPENSSL_DIR
)
130 @echo XMLDIR
=$(XMLDIR
)
131 @echo PLATFORM
=$(PLATFORM
)
134 # Add your rules here if necessary...
137 run
: $(TARGET
) .
/config.cfg