1 .TH compiler 1 "October 2014" "Ericsson Telecom AB" "TTCN-3 Tools"
3 compiler \- TTCN-3 and ASN.1 to C++ translator
6 .RB "[\| " \-abcdfgijlLMpqrRsStuwxXyY " \|]"
8 .IR " verb_level" " \|]"
16 .IR " top_level_pdu" " \|] ..."
20 .IR "none|type" " \|] "
25 [\| \- module.ttcn ... module.asn ... \|]
34 .B compiler \-\-ttcn2json
35 .RB "[\| " \-jf " \|]"
44 This manual page is a quick reference for the TTCN-3 and ASN.1 to C++ (or JSON schema)
45 compiler of the TTCN-3 Test Executor. It only summarizes the meaning of
46 all command line options. For more details please consult the
47 .B Programmer's Technical Reference for TITAN TTCN-3 Test Executor.
49 The following options are supported (in alphabetical order):
52 Forces the interpretation of
56 It is useful when automatic module type detection fails
57 due to some strange language constructs. The option takes exactly one file
58 name as argument. The option must be repeated when used with multiple files.
68 Disables the generation of
70 encoder/decoder routines for all ASN.1 types.
80 fields with DEFAULT values as
85 Forces the compiler to
87 the output files even if they exist or are unchanged.
90 The compiler error/warning messages will contain only the starting
91 line number and column, in a format compatible with th GNU compiler (gcc).
95 if both are specified.
98 The compiler error/warning messages
101 the column numbers will remain hidden. This option provides backward
102 compatibility with the error message format of earlier versions.
105 Disables JSON encoder/decoder functions.
108 Enables selective code coverage.
111 Instructs the compiler to generate source file and line information (i.e.
113 directives) into the output C++ code so that the C++ compiler error
114 messages refer back to the lines of original TTCN-3 input module.
118 and will be removed in future versions as the
119 compiler does not generate erroneous C++ code because of the full
123 Instructs the compiler to add source file and line
127 information into the generated code to be included in the
131 This option is only a prerequisite for logging the source code information.
136 have also to be set appropriately in section
138 of the run-time configuration file.
140 Usage of this option a bit enlarges the size of the generated code and slightly
141 reduces execution speed. This flag is not recommended when the TTCN-3 test
142 suite is used for load generation.
145 Allows the use of the value
147 in template lists and complemented template lists (legacy behavior).
148 If set, an omitted field will match a template list, if the value
150 appears in the list, and it will match a complemented template list, if
152 is not in the list (the
154 attribute can still be used for matching omitted fields). This also affects the
158 template restriction accordingly.
161 The output files (including Test Port skeletons) will be placed into
162 the directory specified by
164 The current working directory is the default otherwise.
167 Instructs the compiler only to
169 the given TTCN-3 and ASN.1 modules. This will detect only the syntax errors
170 because semantic checkings are
172 performed. The presence of all imported modules is not necessary thus it is
173 allowed (and recommended) to parse the modules one-by-one.
175 All options that influence the code generation are silently ignored when used
180 This option includes complete syntax checks for TTCN-3 modules, but in ASN.1
181 there are some special constructs (e.g. the user-defined syntaxes) that cannot
182 be even parsed without semantic analysis. So there is no guarantee that an ASN.1
183 module is free of syntax errors if it was analyzed with compiler using the
187 .BI \-P " top_level_pdu" ...
188 Defines a top-level pdu.
190 must have the following format:
191 .I modulename.identifier.
192 If this switch is used, then only the defined top-level PDU(s) and the
193 referenced assignments are checked and included in code generation, the
194 other ASN.1 assignments are skipped.
198 mode. Equivalent with
208 Disables the generation of
210 encoder/decoder routines for all TTCN-3 types.
213 Use function test runtime (TITAN_RUNTIME_2). The compiler will generate source
214 code for use with function test runtime.
217 Instructs the compiler to parse the given TTCN-3 and ASN.1 modules and perform
221 to generate C++ output. The list of given modules shall be complete so it is
222 not allowed to import from a module that is not in the list. All options that
223 influence the code generation are silently ignored when used together with
233 skeleton header and source files for all port types that can be found in
234 TTCN-3 modules. Existing Test Port files will not be overwritten unless the
239 Forces the interpretation of
247 Forces the compiler to do
248 .I duplicate underscore
249 characters in all output file names. This option turns on the
250 compatibility mode with versions 1.1 or earlier.
253 Selects code splitting mode for the generated C++ code.
258 and license key information and exits.
260 .BI \-V " verb_level"
261 Sets the verbosity bit-mask directly to
265 is a decimal value between 0 and 65535).
274 "NOT SUPPORTED" messages.
285 The debug-bits act like a 3-bits-length number, so the debug level has
286 a value between 0 and 7. It is useful in case of abnormal program termination.
294 messages. Equivalent with
298 Disables the generation of
300 encoder/decoder routines for all TTCN-3 types.
305 encoder/decoder functions
313 Enforces legacy behaviour of the "out" function parameters (see refguide).
316 Enables profiling and code coverage in the selected TTCN-3 files. The
318 argument contains a list of TTCN-3 files separated by new lines. Each TTCN-3 file must be among the compiler's TTCN-3 file arguments.
321 The single dash character as command line argument controls the
322 .I selective code generation
324 After the list of all TTCN-3 and ASN.1 modules a subset of these files can
325 be given separated by a dash. This option instructs the compiler to parse all
326 modules, perform the semantic analysis on the entire module hierarchy, but
329 for those modules that are listed after the dash again.
331 It is not allowed to specify a file name after the dash that was not present
332 in the list before the dash. If the single dash is not present in the command
333 line the compiler will generate code for
338 Generates a JSON schema from the types defined in the specified TTCN-3 and ASN.1 modules.
339 Must always be the first compiler option. From the previously listed options only
343 can be used, instead the JSON schema generator has options of its own:
346 Only types that have JSON coding enabled are included in the schema.
349 The schema only validates types that have a JSON encoding or decoding method declared.
352 The single dash character as command line argument specifies the name of the generated
353 JSON schema file. If it is not present, then the schema file name is generated from
354 the name of the first input file (by replacing its suffix with
358 to the end of the file).
360 The compiler exits with a status of zero when no errors were encountered
361 during its operation. A status of one will be returned if syntax or
362 semantic errors were detected in the input modules.
363 .SH ENVIRONMENT VARIABLES
367 The installation directory where the uncompressed binary package of
368 TTCN-3 Test Executor can be found.
372 It shall point to the
376 to its directory) that contains the personalized license key for the
377 current user or host.
379 The compiler does not support all constructs of TTCN-3 Core Language and ASN.1.
380 It reports an error when encountering an unsupported language element.
381 The detailed list of deficiencies and language extensions can be found in the
382 referenced documentation.
384 For trouble reporting use the tool
386 For TR writers guide please visit the web page:
387 .I http://ttcn.ericsson.se.
391 Ericsson document 2/198 17-CRL 113 200 Uen:
392 .B Programmer's Technical Reference for TITAN TTCN-3 Test Executor
395 ETSI Standard ES 201-873-1:
396 .B Testing and Test Control Notation: TTCN-3 Core Language
399 ITU-T Recommendations X.680-683:
400 .B Abstract Syntax Notation One (ASN.1)
402 This manpage is written by Janos Zoltan Szabo, Ericsson Telecom AB
404 Copyright (c) 2000-2015 Ericsson Telecom AB
406 All rights reserved. This program and the accompanying materials
407 are made available under the terms of the Eclipse Public License v1.0
408 which accompanies this distribution, and is available at
410 http://www.eclipse.org/legal/epl-v10.html