Intel® C++ Compiler 19.0 Developer Guide and Reference Supplement for Intel® System Studio 2019

Using the Compiler with Eclipse*

Using the Compiler with Eclipse*

The Intel® System Studio installation automatically integrates the Intel® C++ Compiler into a preexisting Eclipse* CDT installation. For information on which versions of Eclipse* are supported, see the Intel® System Studio Release Notes.

To set up the cross-build options for embedded Linux* targets, follow these steps:

  1. In Eclipse, select File -> New -> Project.

  2. Select Application Development -> Project to cross-compile for Linux and Android targets.

  3. Specify the configuration for cross compilation (Yocto 2.2 is used as an example):



  4. Finish creating the project.

  5. Build the project.

You can modify cross-compilation settings later in Project Properties:

  1. Select a project in the Project Explorer and open Project/Properties.

  2. To change the GNU toolchain path select C/C++ Build -> Environment and modify the GNU_CROSS_TOOLCHAIN_BIN_PATH variable.

  3. To change SYSROOT or GNU PREFIX select Intel® System Studio Settings:



  4. Select Apply to All Configurations to use the file for all configurations in the current project.

  5. Click OK to close the dialog.

Note

By default, the Intel® C++ compiler generates code for Intel® 64 architecture. If you want to generate code for IA-32 architecture, please specify compiler option -m32 in Project/Properties -> Intel C++ Compiler (or Intel C Compiler) -> Command Line -> Additional Options and Intel Linker -> Miscellaneous -> Additional options.

Note

Starting with Android NDK r16, you must specify the following:

-D__ANDROID_API__=<API version>

in Project/Properties -> C/C++ Build -> Intel C/C++ Compiler -> Command Line -> Additional Options.

For more details, see Unified Headers at https://android.googlesource.com/platform/ndk/+/ndk-release-r16/docs/UnifiedHeaders.md .

For detailed information on using the compiler with Eclipse, see Using Eclipse in the Intel® C++ Compiler 19.0 Developer Guide and Reference.