When you set the project properties for your C or C++ project, the relevant properties apply to all folders and files in the project.
By default, a file inherits the code assistance properties, include directories, preprocessor definitions, and C/C++ standard from the project. You can choose to have a file not inherit these properties.
To modify a file property:
The General node shows the following properties for a specific file in addition to the name and file path:
Has Code Assistance. Indicates the code assistance state and is dynamically determined.
Add to Parse. Select this option to enforce parsing of the file. This can be used to parse extra headers not included by any compilation units or to manually add the file as an extra compilation unit.
The Compiler node shows the following properties:
Include Directories. Type the absolute or relative path to the directories containing headers for your project, or click the button to browse to the directories and add them. On the file browser dialog box, you can specify Absolute or Relative path.
Include Headers. Type the filename of the header file to include or click the button to browse to the file and add it. This option causes the compiler to treat the header file as if it appears in your source files as an #include directive.
Preprocessor Definitions. Add definitions for macros used by the project. Click the text field or the button to open the Preprocessor Definitions dialog box to add definitions.
Preprocessor Undefined. Add definitions for macros used by the project. Click the text field or the button to open the Preprocessor Definitions dialog box to add definitions.
C Standard. Specifies whether project sources should be parsed as C89, C99, or C11 code. When set to Default, use the compiler's default C standard.
C++ Standard. Specifies whether project sources should be parsed as C++98 code or C++11 code. When set to Default, use the compiler's default C++ standard.
See also | |
---|---|
Setting C and C++ Compiler
Options C/C++ Project Properties Dialog Box: Compiler (General) |
Copyright © 2014, Oracle and/or its affiliates. All rights reserved.