IDE Window: Configure Build file

Normally 'building' and 'running' menu items and shortcuts invokes building (running) the current project.

With this dialog you can override this behaviour for each file. This is useful, if you created a small test program or a sub project. Then you can compile them without changing the project. These settings are stored with the project (.lpi file). They are not global settings.

Build / Run File

edit

The IDE can build and run single files instead of the project. For example when pressing the Run button, the IDE checks if you enabled this feature for the current source file in the source editor. If yes, the IDE executes the Run File command instead. The information how to build or run a file is stored as IDE directives in the source file itself and can be setup via the dialog described on this page (Run / Configure Build+Run File).

Options

edit

When this file is active in the source editor ...

To override the behaviour for run and/or build by checking the appropriate checkbox.

  • On build project execute the Build File command instead
  • On run project execute the Run File command instead

Build

edit

Working directory

edit

Before building, change to this directory. Relative paths in the build command will then be relative to this directory.

Build Command

edit

Provide the command to call for building the file. The default is:

 $(CompPath) $(EdFile)

Scan for FPC messages

edit

Parse output for FPC errors and hints. The IDE will jump to errors.

Scan for Make messages

edit

Parse output for 'Make' errors and hints. The IDE will jump to errors.

Macros

edit

IDE Macros in paths and filenames

Run

edit

Always build before run

edit

If checked, the Build File command is executed before running.

Working directory

edit

Before running, change to this directory. Relative paths in the run command will then be relative to this directory.

Run Command

edit

Provide the command to call to run file. The default is:

 $MakeExe($(EdFile))

Macros

edit

IDE Macros in paths and filenames

IDE directives

edit
  • BuildCommand
  • BuildWorkingDir
  • BuildScan
  • RunCommand
  • RunWorkingDir
  • RunFlags

See IDE directives.