The Intel
By default, the libraries are linked as follows:
Fortran, math and libcprts.a libraries are linked at link time, that is, statically.
libcxa.so is linked dynamically to conform to C++ ABI.
GNU and Linux system libraries are linked dynamically.
This approach
Enables to maintain the same model for both IA-32 and Itanium compilers.
Provides a model consistent with the Linux model where system libraries are dynamic and application libraries are static.
The users have the option of using dynamic versions of our libraries to reduce the size of their binaries if desired.
The users are licensed to distribute Intel-provided libraries.
The libraries libcprts.a and libcxa.so are C++ language support libraries used by Fortran when Fortran includes code written in C++.
The main options used with shared libraries are -i_dynamic and -shared.
The -i_dynamic option can be used to specify that all Intel-provided libraries should be linked dynamically. The comparison of the following commands illustrates the effects of this option.1. prompt>ifc myprog.f
This command produces the following results (default):
Fortran, math, libirc.a, and libcprts.a libraries are linked statically (at link time).
Dynamic version of libcxa.so is linked at run time.
The statically linked libraries increase the size of the application binary, but do not need to be installed on the systems where the application runs.
2. prompt>ifc -i_dynamic myprog.f
This command links all of the above libraries dynamically. This has the advantage of reducing the size of the application binary, but it requires all the dynamic versions installed on the systems where the application runs.
The -shared option instructs the compiler to build a Dynamic Shared Object (DSO) instead of an executable. For more details, refer to the ld man page documentation.