| |||
| Home > Getting started with the Compiler > Compiler command-line options and search paths | |||
Table 2-2 shows how the specified compiler command-line options affect the search path used by the compiler when it searches for header and source files.
Table 2. Include file search paths
| Compiler option | <include> search order | "include" search order |
|---|---|---|
Neither -I nor -J | ARMCC,
then ARMINC, then ../include | Current Working Directory (CWD) then ARMCC,
then ARMINC, then ../include |
-I | ARMCC,
then ARMINC, then ../include,
then the directory or directories specified by -I | CWD then the directory or directories specified
by -I then ARMCC,
then ARMINC, then ../include |
-J | The directory or directories specified by -J | CWD then the directory or directories specified
by -J |
Both -Iand -J | The directory or directories specified by -Jand then
the directory or directories specified by -I | CWD then the directory or directories specified
by -Iand then
the directory or directories specified by -J |
| No effect | Removes CWD from the search path |
| No effect | Uses Kernighan and Ritchie search rules |
Compiler Reference:
Introducing the ARM Compiler toolchain:
Kernighan, B.W. and Ritchie, D.M., The C Programming Language (2nd edition, 1988). Prentice-Hall, Englewood Cliffs, NJ, USA. ISBN 0-13-110362-8.