Skip to content

Using AFNetworking - can't import header #1082

Closed
LeChatNoir69 opened this Issue Dec 17, 2012 · 5 comments

3 participants

@LeChatNoir69

Hi,
I'm using RestKit in my project. Works fine.

But I want to use some AFNetwork methods too.
So I tried to import headers but XCode don't find header...

Does I have to include AFNetworking as a standalone library ? As it is already included in Restkit, I thought it would be enough...

But maybe I missed something ?

@blakewatters
The RestKit Project member

Did you install via CocoaPods or as a standalone library?

@LeChatNoir69

standalone... Does it matter ?

@cmollis
cmollis commented Dec 17, 2012

https://github.com/RestKit/RestKit/wiki/Installing-RestKit-in-Xcode-4.x

Remember to do this:

git submodule update --init --recursive

this should get the dependencies (AFNetworking) if I'm not mistaken..

@blakewatters
The RestKit Project member

Are you using iOS or OS X? I just pushed an update for the OS X Framework target -- the AFNetworking headers were not marked as Public. This is fixed on development.

In any case, with a standalone import your should be able to do #import <RestKit/AFNetworking.h>

@blakewatters
The RestKit Project member

This actually shouldn't even be necessary. If you have RestKit imported, the RKObjectManager.h import pulls in the full AFNetworking.h header. You should be able to just create the operations directly without doing any imports.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.