Fixing link-time problems

After the XL Fortran compiler processes the source files, the linker links the resulting object files together. Any messages issued at this stage come from the ld command. A frequently encountered error and its solution are listed here for your convenience:

Undefined or unresolved symbols detected

Message:
filename.o(.text+0x14): undefined reference to "p"
filename.o(.text+0x14): relocation truncated to fit: R_PPC_REL24 p
System action:
A program cannot be linked because of unresolved references.
Explanation:
Either needed object files or libraries are not being used during linking, there is an error in the specification of one or more external names, or there is an error in the specification of one or more procedure interfaces.
User response:
You may need to do one or more of the following actions:
  • Compile again with the -Wl or -M option to create a file that contains information about undefined symbols.
  • Make sure that if you use the -qmixed option, all intrinsic names are in lowercase.