Intel® Fortran Compiler Classic and Intel® Fortran Compiler Developer Guide and Reference

ID 767251
Date 9/08/2022
Public

A newer version of this document is available. Customers should click here to go to the newest version.

Document Table of Contents

fpp

Runs the Fortran preprocessor on source files before compilation.

Syntax

Linux:

-fpp

-nofpp

macOS:

-fpp

-nofpp

Windows:

/fpp

/fpp[:"fpp_option"]

/nofpp

Arguments

fpp_option

Is a Fortran preprocessor (fpp) option; it must start with a slash (/) and appear in quotes. This argument is only allowed on Windows* systems.

Default

nofpp

The Fortran preprocessor is not run on files before compilation.

Description

This option runs the Fortran preprocessor on source files before they are compiled.

If you want to pass fpp options to the Fortran preprocessor, you can use any of the following methods:

  • Specify option Qoption,fpp,"option". This is the recommended method.

  • Linux and macOS

    Specify option -Wp,fpp_option (for example, -Wp,-macro=no).

  • Windows

    Specify option fpp and include the argument fpp_option (for example, fpp:"/macro=no").

To see a list of all available fpp options, specify the following on the command line:

Linux and macOS

fpp -help   

Windows

fpp /help    
IDE Equivalent

Visual Studio: Preprocessor > Preprocess Source File

Alternate Options

Linux and macOS: -cpp (this is a deprecated option)

Windows: None

Example

The following examples show the recommended method of passing fpp options to the Fortran preprocessor.

Linux and macOS

This code undefines all predefined macros:

ifort -fpp –Qoption,fpp,"-undef"  file.f90 

Windows

This code disables macro expansion within comments:

ifort /fpp /Qoption,fpp,"/macro=no_com"  file.f90 

See Also