Next: Dynamic Libraries
Up: No Title
Previous: Compilers
- -c
- compile to object code (.o)
- -S
- compile to assembler (.s)
- -E
- send output of cpp to standard output
- -I
- add a directory to the include search path
(used for finding files named in
#include statements.
- -l
- link against a standard system library (eg -lm links
against libm)
- -L
- add a directory to the standard library search
path
- -o
- Give the output a different name. Most useful for the
output of the link step, which by default is a.out.
- -O
- Specify optimisation level. Usually given as a number from
-O0 (no optimisation) to -O3 or -O4. Need to read the compiler
manual.
- -g
- Include symbolic information for debugging purposes.
- -p/-pg
- Instrument code for profiling.
Russell Standish
2001-05-04