Intel® Fortran Compiler 17.0 Developer Guide and Reference

fcommon

Determines whether the compiler treats common symbols as global definitions.

Syntax

Linux and macOS:

-fcommon

-fno-common

Windows:

None

Arguments

None

Default

-fcommon

The compiler does not treat common symbols as global definitions.

Description

This option determines whether the compiler treats common symbols as global definitions and to allocate memory for each symbol at compile time.

Option -fno-common tells the compiler to treat common symbols as global definitions. When using this option, you can only have a common variable declared in one module; otherwise, a link time error will occur for multiple defined symbols.

On OS X, if a library built with the ar utility contains objects with Fortran module data but no executable functions, the symbols corresponding to the module data may not be resolved when an object referencing them is linked against the library. You can work around this by compiling with option -fno-common. For more information, see the article titled: ld: symbol(s) not found when linking library containing no executable functions, which is located in https://software.intel.com/en-us/articles/ld-symbols-not-found-when-linking-library-containing-no-executable-functions

IDE Equivalent

None

Alternate Options

None