2.10 Compiler command-line options and search paths

The following table 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-2 Include file search paths

Compiler option <include> search order "include" search order
Neither -Idir[,dir,...] nor -Jdir[,dir,...]
  1. ARMCC5INC
  2. ARMINC
  3. ../include
  1. The current place.
  2. ARMCC5INC
  3. ARMINC
  4. ../include
-Idir[,dir,...]
  1. ARMCC5INC
  2. ARMINC
  3. ../include
  4. The directory or directories specified by -Idir[,dir,...] .
  1. The current place.
  2. The directory or directories specified by -Idir[,dir,...].
  3. ARMCC5INC
  4. ARMINC
  5. ../include
-Jdir[,dir,...] The directory or directories specified by -Jdir[,dir,...].
  1. The current place.
  2. The directory or directories specified by -Jdir[,dir,...].
Both -Idir[,dir,...] and -Jdir[,dir,...]
  1. The directory or directories specified by -Jdir[,dir,...].
  2. The directory or directories specified by -Idir[,dir,...].
  1. The current place.
  2. The directory or directories specified by -Idir[,dir,...].
  3. The directory or directories specified by -Jdir[,dir,...].
--sys_include
No effect. Removes the current place from the search path.
--kandr_include
No effect. Uses Kernighan and Ritchie search rules.
Related concepts
2.12 The ARMCC5INC environment variable
2.11 Compiler search rules and the current place
2.9 Factors influencing how the compiler searches for header files
Related reference
7.80 -Idir[,dir,...]
7.91 -Jdir[,dir,...]
7.92 --kandr_include
7.159 --sys_include
Non-ConfidentialPDF file icon PDF versionARM DUI0375F
Copyright © 2007, 2008, 2011, 2012, 2014 ARM. All rights reserved.