Comments (4)
If you want your project to use CoconutKit sources only, you must not add libCoconutKit.a to your project (after all, that's the compiled library), you must only use .m and .h files (and resources files). I do not recommend using CoconutKit this way since you will basically compile everything from scratch every time you clean & build your project.
If you still want to use CoconutKit as source files, here is how:
- Add the CoconutKit/Sources and CoconutKit/Resources folders to your project
- Open CoconutKit-dev-Prefix.pch, copy all #import directives, and paste them into your project .pch file
If you are trying to use CoconutKit as a static library file and a set of header files, I strongly recommend sticking to the .staticframework I provide. The .staticframework binaries include special tricks so you do not run into linking issues (have a look at the CoconutKit_bootstrap.m file). If you want to use the static library file without those linking issues, you will need to add the -ObjC and -all_load flags to your project linker flags (which you do not need to do with the .staticframework). There is an associated space overhead, though, which you won't pay if you use the .staticframework.
from coconutkit.
Hmmm, manually adding references to my project is precisely what I was trying to avoid. I usually try to add project dependencies as git submodules and as separate projects in a workspace.
from coconutkit.
Well, it works as well:
- Add CoconutKit.xcodeproj to your project
- Link your project with libCoconutKit.a (target -> Build Phases -> Link Binary With Libraries)
- Add -ObjC to your project / target "Other linker flags" settings. -all_load might be needed as well, though -ObjC was sufficient when I tested it
- Add /path/where/you/store/CoconutKit_1.1.3/CoconutKit/Sources/** to the Header Search Paths
- Link your project against CoreData.framework, MessageUI.framework and QuartzCore.framework as well
- Where you want to use some CoconutKit feature, #import "HeaderFile.h". Alternatively, you may want to open CoconutKit-dev-Prefix.pch, copy all #import directives, and paste them into your project .pch file
from coconutkit.
I was doing most of what you recommended, except for adding the "-ObjC" linker flag, which turns out to be crucial if you're using Categories from your linked library. That's why I was getting an exception when using the className method from NSObject+HLSExtensions.h.
It now works. Thanks for the help!
from coconutkit.
Related Issues (20)
- error: can't exec '/usr/bin/make' (No such file or directory) HOT 19
- HLSTextField doesnโt properly obey its delegate HOT 1
- [Support Question] Navigation stack with bar HOT 4
- CocoaPod for 2.0.x HOT 2
- ContainerStack popAll crash HOT 1
- StackViewController removeViewControllerAtIndex issue
- ios
- make-fmwk.sh is missing HOT 3
- Crash with objc_msgSend() selector name: scrollViewDidScroll: in UIScrollView+HLSExtensions.m HOT 4
- Cannot install with latest pods HOT 1
- CoconutKit uses deprecated rotation calls in iOS 8 HOT 3
- Crash on ViewController Lifecycle when running an app with a 3rd party keyboard HOT 4
- Stackoverflow in "swizzle_viewDidLoad" when using custom keyboards HOT 1
- Issues with text views in scrollviews when an external keyboard is connected (iOS 9)
- Sometimes incorrect layout guides when pushing a view controller into a stack controller
- Slow email validation regex
- UITextField bindings not working on iOS 12 HOT 2
- Model manager duplication not working HOT 1
- Browser top and bottom insets incorrect (especially since iOS 11)
- iOS 13 support
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from coconutkit.