Previous Topic Next topic Print topic


Compiler Directives and Project Settings

Controlling the build behavior of projects, including Compiler directives, is achieved by using the project properties, the project build configuration properties or the file properties. You access these by choosing Properties on the context menu for projects, folders and files.

In general, directives and settings that always apply should be set at the project level.

Build configurations should be used to override the project settings with settings that are relevant only to a particular build configuration.

File-level settings override the other settings set at a project or build configuration level.

You can set SQL and CICS preprocessor directives at the project level, even when the project settings are not configured to run the preprocessors. The use of the preprocessors can then be turned on at the file level, which inherits the project level preprocessor directives. This enables you to use the project level as a template for file-level settings.

When COBOL sources are copied into a project from outside the workspace, by default, a process known as directives determination is performed automatically. The IDE detects and sets the correct dialect and use of preprocessors.

You can also trigger directives determination manually using the Determine Directives context menu command for projects, folder and programs in the COBOL Explorer or the PL/I Explorer view. You can turn off or configure this behavior using the Micro Focus > COBOL > Directives Determination page in the IDE preferences (click Window > Preferences). For PL/I projects, you can configure the directives determination from the Micro Focus > PL/I > Directives Determination page in the IDE preferences.

Dependency Path Handling

The Automatically add new directories to dependency paths preference on the Window > Micro Focus > Builder page in the IDE preferences (click Window > Preferences) controls whether adding a directory to a project also causes the directory to be added as an enabled item onto the dependency paths of the project. If you add a new copybook in a new folder and your build fails, you should check whether this preference is enabled or disabled and also check the project dependency paths settings.

Previous Topic Next topic Print topic