How does Xcode know where to look for infrastructure?

Example: I import the framework as follows:

#import <Cocoa/Cocoa.h>

Now, what is this Cocoa / Cocoa.h path? I mean ... where does the Xcode search come from? Where is it configured? And is it really a path or something else? What is Cocoa / Cocoa.h? Is the namespace and structure there? Or what else?

+5
source share
2 answers

This is in the xcode documentation:

http://developer.apple.com/mac/library/documentation/DeveloperTools/gcc-4.0.1/cpp/Search-Path.html#Search-Path

2.3 The GCC search path looks in different places for headings. On a regular Unix system, unless you specify it otherwise, it will look for the headers requested by C # include in:

 /usr/local/include
 libdir/gcc/target/version/include
 /usr/target/include
 /usr/include

++ /usr/include/g ++ - v3. - , GCC ; , , , . - GCC.

</ >

+4

... Xcode Xcode Foundation . , .

Framework Xcode, Frameworks , , Xcode. Xcode "~/Library/Frameworks", "/Library/Frameworks" "/System/Library/Frameworks". , "-framework" GCC, . , GCC , "-framework", DYLD_FALLBACK_FRAMEWORK_PATH.

:
, "Cocoa/" - . , Framework "", . Framework Xcode, "" , , (.. "Cocoa/Cocoa.h" "/System/Library/Frameworks/ Cocoa.framework/Headers/Cocoa.h", "/System/Library/Frameworks/Cocoa.framework/Headers/Cocoa/Cocoa.h" )

+1

All Articles