There are six methods of specifying a nonnative numeric format for unformatted data:
Setting an environment variable for a specific unit number before the file is opened. The environment variable is named FORT_CONVERTn, where n is the unit number. See Environment Variable FORT_CONVERTn Method.
Setting an environment variable for a specific file name extension before the file is opened. The environment variable is named FORT_CONVERT.ext or FORT_CONVERT_ext, where ext is the file name extension (suffix). See Environment Variable FORT_CONVERT.ext or FORT_CONVERT_ext Method.
Setting an environment variable for a set of units before the application is executed. The environment variable is named F_UFMTENDIAN. See Environment Variable F_UFMTENDIAN Method.
Specifying the CONVERT keyword in the OPEN statement for a specific unit number. See OPEN Statement CONVERT Method.
Compiling the program with an OPTIONS statement that specifies the CONVERT=keyword qualifier. This method affects all unit numbers using unformatted data specified by the program. See OPTIONS Statement Method.
Compiling the program with the appropriate compiler option, which affects all unit numbers that use unformatted data specified by the program. Use the -convert keyword option for Linux* and Mac OS* or, for Windows*, the command-line /convert:keyword option or the IDE equivalent.
If none of these methods are specified, the native LITTLE_ENDIAN format is assumed (no conversion occurs between disk and memory).
Any keyword listed in Supported Native and Nonnative Numeric Formats can be used with any of these methods, except for the Environment Variable F_UFMTENDIAN Method, which supports only LITTLE_ENDIAN and BIG_ENDIAN.
If you specify more than one method, the order of precedence when you open a file with unformatted data is to:
Check whether the compiler option -convert keyword (Linux and Mac OS) or /convert:keyword (Windows) was present when the program was compiled.