Update static library instruction to be more comprehensive.
This commit is contained in:
parent
8e27086802
commit
7030a8f802
20
README.md
20
README.md
|
@ -203,20 +203,27 @@ The following instructions are adapted from the excellent "Using Open Source Sta
|
||||||
|
|
||||||
### Add the SDWebImage project to your workspace
|
### Add the SDWebImage project to your workspace
|
||||||
|
|
||||||
Right-click on the project navigator and select "Add Files to "Your Project" and select the SDWebImage
|
Make sure your project is in a workspace. If it's not, click File -> Save As Workspace first.
|
||||||
Xcode project.
|
|
||||||
|
Right-click on the project navigator and select "Add Files to "Your Project" and select SDWebImage.xcodeproj.
|
||||||
|
You may want to include the SDWebImage directory in your workspace repository before adding it to your project.
|
||||||
|
|
||||||
![Add SDWebImage](http://blog.carbonfive.com/wp-content/uploads/2011/04/adding_an_existing_project.png?w=300)
|
![Add SDWebImage](http://blog.carbonfive.com/wp-content/uploads/2011/04/adding_an_existing_project.png?w=300)
|
||||||
|
|
||||||
You should end up with your project and SDWebimage project at the same lever in the workspace.
|
You should end up with your project and SDWebimage project at the same level in the workspace.
|
||||||
|
|
||||||
|
### Build libSDWebImage.a File
|
||||||
|
|
||||||
|
Set your build target to iOS Device, then click Build. Make sure the libSDWebImage.a file inside SDWebImage -> Products is not red.
|
||||||
|
|
||||||
### Add build target dependency
|
### Add build target dependency
|
||||||
|
|
||||||
Select your project's build target and add the 'libSDWebImage.a' library to the "Link Binary With Libraries"
|
Select your project's build target and add the 'libSDWebImage.a' library to the "Link Binary With Libraries" inside the "Build Phases" tab.
|
||||||
build phase.
|
|
||||||
|
|
||||||
![Add target dependency](http://blog.carbonfive.com/wp-content/uploads/2011/04/linkable_libraries.png?w=214)
|
![Add target dependency](http://blog.carbonfive.com/wp-content/uploads/2011/04/linkable_libraries.png?w=214)
|
||||||
|
|
||||||
|
You may also need to add MapKit.framework here too as 'MKAnnotationView_WebCache.h' depends on it.
|
||||||
|
|
||||||
### Add headers
|
### Add headers
|
||||||
|
|
||||||
Open the "Build Settingsæ tab and locate the "User Header Search Paths" setting. Set this to
|
Open the "Build Settingsæ tab and locate the "User Header Search Paths" setting. Set this to
|
||||||
|
@ -226,6 +233,9 @@ Open the "Build Settingsæ tab and locate the "User Header Search Paths" setting
|
||||||
|
|
||||||
Add the "-ObjC" flag to the "Other Linker Flags" build setting.
|
Add the "-ObjC" flag to the "Other Linker Flags" build setting.
|
||||||
|
|
||||||
|
### Build Project
|
||||||
|
At this point your workspace should build without error. If you are having problem, post to the Issue and the community can help you solve it.
|
||||||
|
|
||||||
### Fixing indexing
|
### Fixing indexing
|
||||||
|
|
||||||
If you have problem with auto-completion of SDWebImage methods, you may have to copy the header files in
|
If you have problem with auto-completion of SDWebImage methods, you may have to copy the header files in
|
||||||
|
|
Loading…
Reference in New Issue