Intel® C++ Compiler XE 13.1 User and Reference Guides

Invoking the Intel® C++ Compiler

Requirements Before Using the Command Line

On Linux* OS and OS X*, you need to set some environment variables to specify locations for the various components prior to using the command line. The Intel® C++ Compiler installation includes a shell script that you can run to set environment variables. For more information, see Using the compilervars File to Specify Location of Components.

Using the Compiler from the Command Line

You can invoke the Intel® C++ Compiler on the command line with the corresponding command.

Linux OS* and OS X*:

The command is either icc or icpc.

The icc or icpc command does the following:

Because the driver calls other software components, error messages may be returned by these other components. For instance, the linker may return a message if it cannot resolve a global reference. The -watch command-line option can help clarify which component is generating the error.

Command-line Syntax

When you invoke the Intel® C++ Compiler, the syntax is:

Linux* OS and OS X*

{icc|icpc} [options] file1 [file2 . . .]

Argument

Description

options

Indicates one or more command-line options. The compiler recognizes one or more letters preceded by a hyphen (-).

Options are not required when invoking the compiler. The default behavior of the compiler implies that some options are ON by default when you invoke compiler.

Note

On Linux* OS systems, the compiler recognizes Language Extensions for Offloading in the source program by default and builds a heterogeneous binary that runs on both the target and host when any are present. If your program includes these language extensions and you do not want to build a heterogeneous binary, specify the -no-offload compiler option. For more information, see the Programming for Intel® MIC Architecture: Heterogeneous Programming section and the -no-offload compiler option.

file1, file2 . . .

Indicates one or more files to be processed by the compiler. You can specify more than one file. Use a space as a delimiter for multiple files.

See Also


Submit feedback on this help topic