1. Apple does not allow calling external frameworks and DLL, so it is two methods to use open source code to pour the source code into the project or make a static library.
2. The architecture of the library used on the simulator and device is different. The former is i386 and the latter is armv6 and 7. So if you do the database, you can see what it is used. You can use commands to view the architecture of your database.
Lipo-info/path/to/Your/library.
3. How to import the imported header file
C code, headers is usually used in this way # include <fuck. h>. If we use this method, xcode directly reports an error, prompting that such a header file cannot be found. Right-click your project name and select get info. On the build tab, the search hearder path option is available. Is to let you tell xcode where to search for the header file.
============
1. Drag. xcodeproj of the static library to the frameworks directory of the project.
2. Drag the. A file of the static library to the frameworks directory. Do not select "Copy items ..."
3 Add "target dependencies"
4. Add the header file path to "header search path"
5. Directly import the header file during the call.
# Import "JSON. H"
============
Xcode 4.2
1. xcode4-> Target-> build phases-> link binary with libraries-> add items
2. Add the header file of the corresponding Library to the code.
============
1. Add the project file of the library directly in the framework (this step does not know if it is necessary. In this case, all the library files will be visible)
2. Click the total project file in the tree structure in the upper left corner and select your project target file in the intermediate target file.
3. Select the build phases tag on the right.
4. Select the library compilation file (. A) in link binary with library)
5. Create a link between the target file and the library file, and add the Library to the target dependencies label on link binary with liibrary.
6. compile.
Address: http://hi.baidu.com/marktian/item/39803f8f37ab13834414cff8