4.4 Control Program Options

The control program cctc facilitates the invocation of the various components of the TriCore toolchain from a single command line. The control program is a command line tool so there are no equivalent options in EDE.

For the linker options in EDE, EDE invokes the linker via the control program. Therefore, it uses the syntax of the control program to pass options and files to the linker. See section 4.3 , Linker Options, for an overview of the EDE linker options and the corresponding command line linker options.

Some options are interpreted by the control program itself; other options are passed to those programs in the toolchain that accept the option.

Recognized input files

The control program recognizes the following input files:

Normally, the control program tries to compile, assemble, link and locate all source files to absolute object files. There are however, options to suppress the assembler, link or locate stage.

-?

Command line syntax

Description

Displays an overview of all command line options.

Example

The following invocations all display a list of the available command line options:

Related information

-

-C

Command line syntax

Description

With this option you define the target processor for which you create your application. Default the control program generates an object file for the TC10GP.

Based on the target processor, the compiler includes the register file regcpu.sfr and the assembler includes the file regcpu.def.

Example

In EDE, the target CPU has the following settings:

To define this on the command line:

The control program generates an absolute object file test.elf for the TC10GP processor. The compiler includes the register file regtc10gp.sfr and the assembler includes the file regtc10gp.def.

Related information

Compiler option -C (Use SFR definitions for CPU)

Assembler option -C (Select CPU)

Section 5.5, Specifying a Target Processor, in Chapter Using the Compiler of the User's Guide.

-c++

Command line syntax

Description

With this option you tell the control program to treat all .c files as C++ files instead of C files. This means that the control program calls the C++ compiler prior to the C compiler and forces the linker to link C++ libraries.

Example

The file test.c is considered to be a C++ file.

Related information

Control program option -noc++ (Force C++ files to C mode)

-cc/-cs/-c/-cl

Command line syntax

Description

Normally the control program generates an absolute object file of the specified output format from the file you supplied as input.

With this option you tell the control program to stop after a certain number of phases.

Example

To generate the object file test.o:

The control program stops after the file is assembled. It does not link nor locate the generated output.

Related information

-

-cm

Command line syntax

Description

With this option you force the control program to invoke the C++ muncher.

Example

The control program always invokes the C++ muncher when generating test.elf.

Related information

-

-cp

Command line syntax

Description

With this option you force the control program to invoke the C++ pre-linker.

Example

The control program always invokes the C++ pre-linker when generating test.elf.

Related information

-

-elf

Command line syntax

Description

With this option you tell the control program to generate an ELF/DWARF object file.

Example

The control program generates the ELF/DWARF object file test.elf from test.c.

Related information

Linker option -Fformat (Output format)

Section 6.1, ELF/DWARF Object Format, in Chapter Object File Formats.

-f

Command line syntax

Description

Instead of typing all options on the command line, you can create a option file which contains all options and file you want to specify. With this option you specify the option file to the control program.

Use an option file when the length of the command line would exceed the limits of the operating system, or just to store options and save typing.

You can specify the option -f multiple times.

Format of an option file

     "This has a single quote ' embedded"
     'This has a double quote " embedded'
     'This has a double quote " and \
     a single quote '"' embedded"
     "This is a continuation \
     line"
          -> "This is a continuation line"

Example

Suppose the file myoptions contains the following lines:

Specify the option file to the control program:

This is equivalent to the following command line:

-fptrap

Command line syntax

Description

Default the control program uses the non-trapping floating point library (libfp.a). With this option you tell the control program to use the trapping floating point library (libfpt.a).

If you use the trapping floating point library, exceptional floating point cases are intercepted and can be handled separately by an application defined exception handler. Using this library decreases the execution speed of your application.

Example

Link the trapping floating point library when generating the object file test.elf.

Related information

-

-ieee

Command line syntax

Description

With this option you tell the control program to generate an IEEE-695 object file.

Example

The control program generates the IEEE-695 object file test.abs from test.c.

Related information

Linker option -Fformat (Output format)

-ihex

Command line syntax

Description

With this option you tell the control program to generate an Intel hex object file.

Example

The control program generates the Intel hex object file test.hex from test.c.

Related information

Linker option -Fformat (Output format)

Section 6.3, Intel Hex Record Format, in Chapter Object File Formats.

-noc++

Command line syntax

Description

With this option you tell the control program to treat all .cc files as C files instead of C++ files. This means that the control program does not call the C++ compiler and forces the linker to link C libraries.

Example

The C++ file test.cc is considered to be a normal C file.

Related information

Control program option -c++ (Force C files to C++ mode)

-nolib

Command line syntax

Description

Default the control program specifies the standard C libraries and run-time library to the linker.

With this option you tell the control program not to specify the standard C libraries and run-time library to the linker.

In this case you must specify the libraries you want to link to the linker with the option -llibrary_name. The control program recognizes the option -l as an option for the linker.

Example

The control program does not specify any libraries to the linker. In normal cases this would result in unresoved externals.

To specify your own libraries (libmy.a) and avoid unresolved externals:

Related information

Linker option -l (Search also in system library libx.a)

-nomap

Command line syntax

Description

Default the control program generates a linker map file (.map). With this option you tell the control program to skip the generation of a linker map file.

Example

The control program does not generate the linker map file test.map.

Related information

Linker option -M (Generate map file)

-o

Command line syntax

Description

Default, the control program generates a file with the same basename as the first specified input file. With this option you specify another name for the resulting absolute object file.

Example

The control program generates an ELF/DWARF object file (default) with the name test.elf.

To generate the file result.elf:

Related information

-

--silicon-bug

EDE

1. From the Project menu, select Project Options...

2. Expand the Processor entry and select Bypasses.

3. Select the bypasses you want to enable.

Command line syntax

You can give one or more of the following arguments:

Description

With this option the control program tells the compiler/assembler/linker to use software workarounds for some CPU functional problems.

Example

The compiler uses workarounds for TC113 problems CPU5 and CPU9.

Related information

See Chapter 8 , CPU Functional Problems, for more information about the individual problems and workarounds.

-srec

Command line syntax

Description

With this option you tell the control program to generate a Motorola S-record object file.

Example

The control program generates the Motorola S-record object file test.sre from test.c.

Related information

Linker option -Fformat (Output format)

Section 6.2, Motorola S-record Format, in Chapter Object File Formats.

-tmp

Command line syntax

Description

Default, the control program removes intermediate files like the .src file (result of the compiler phase) and the .out file (result of the linking phase).

With this option you tell the control program to keep temporary files it generates while creating the absolute object file.

Example

The control program keeps all intermediate files it generates while creating the absolute object file test.elf.

Related information

-

-Wtool

Command line syntax

Description

With this option you tell the control program to call a tool with the specified option. The control program does not use the option itself, but specifies it directly to the tool which the control program calls.

Example

The control program does not use the option -r but calls the linker with the option -r (ltc -r).

Related information

-

-V

Command line syntax

Description

Display version information. The control program ignores all other options or input files.

Example

The control program does not call any tools but displays the following version information:

Related information

-

-v/ -v0

Command line syntax

Description

With this option you put the control program in verbose mode. With the option -v the control program performs it tasks while it prints the steps it performs to stdout. With the option -v0 the control program only prints the steps it would do without actually performing these steps.

Example

The control program processes the file test.c and displays the steps it performs:

Related information

-

-wc++

Command line syntax

Description

The C++ compiler may generate a compiled C++ file (.ic) that causes warnings during compilation or assembling. With this option you tell the control program to show these warnings. Default C++ warnings are suppressed.

Example

The control program calls the C++ compiler which generates the C file (test.ic). If this file causes warnings during compilation or assembling, these warnings are shown.

Related information

-


Copyright © 2003 Altium BV