Controlling Compilation

If no errors occur during processing, you can use the output files from a particular phase as input to a subsequent compiler invocation. The following table describes the options to control the output:

Option Input Output
-P
  • Source files
Preprocessed files (.i files).
-E
  • Source files
Preprocesses source file and directs output to stdout.
-EP
  • Source files
Preprocesses source file, directs output to stdout, and omits line numbers.
-c
  • Source files
  • Preprocessed files
Compile to object only (.o), do not link.
-S
  • Source files
  • Preprocessed files
Generate assemblable files with .s suffix and stops the compilation process.
-syntax
  • Source files
  • Preprocessed files
Emits diagnostic list of syntax errors to sdtout. There is no output for source files free of syntax errors.
(Default)
  • Source files
  • Preprocessed files
  • Assemblable files
  • Object files
  • Libraries
Executable file (.out files).