I'm relatively new to XCode and iOS. My background for understanding how to add libraries/dependencies to a project is in the world of Java and Maven.
I need to add AFNetworking to my project and have been unable to do so successfully.
First, I tried going to my project -> Build Phases -> Link Binary
With Libraries, clicking the "+" button, and then search for AFNetworking
from the list. It wasn't in the list.
So, I figured I'd have to add it using the "Add Other..." option. Which means, of course, I'd need to download AFNetworking
somehow. I'm not sure I was able to download it in the correct form -- it seems all I could get was the AFNetworking
project itself, rather than a framework (if I understand correctly, frameworks are analogous to jars? Can you generate a framework by building an iOS project in a certain way?). I downloaded it from their GitHub page. (I also tried their "Getting Started" guide, but it had me using CocoaPods
, which I couldn't get to work right and I'd rather avoid it for now.)
I've tried adding project files and folders from AFNetworking
just to see if they worked (but of course they don't -- I think I need some sort of .framework
file).
Bottom line: I can't seem to find a way to add AFNetworking
to my project. How can I do it?