I am implementing push notification using pushwoosh on my iOS app made with phonegap/cordova.
I followed this tutorial (but stuck on step 1): http://www.pushwoosh.com/programming-push-notification/ios/ios-additional-platforms/push-notification-sdk-integration-for-phonegap/
I downloaded the SDK from here: https://github.com/Pushwoosh/pushwoosh-phonegap-3.0-plugin
I got these files under "ios" directory from SDK:
I can't install the plugin using the terminal so i'm trying to install the plugin manually (if you can send me link on how to install plugins manually and automatically, please do. Thanks), what I did is I dragged the file Pushwoosh.framework into the "Frameworks" folder in my XCode project, then I dragged the Pushnotification.h and Pushnotification.m to the "Classes" folder. When I build and run the app, the following error appears:
Lexical or Preprocessor 'PushNotificationManager.h' file not found
and it's highlighting the following code on PushNotification.h:
#import "PushNotificationManager.h"
What does this error mean?
What did I do wrong?
What is the correct way to install these plugins manually?
Thank you.
Update:
I changed
#import "PushNotificationManager.h"
to
#import <Pushwoosh/PushNotificationManager.h>
and now I get tons of Apple Mach-O Linker error messages saying
"Undefined symbols for architecture i386"
Okay, i fixed the problem and I'm going to share it if ever anyone experience (exactly) the same:
The link that I downloaded the SDK from is for native applications, so I downloaded it from the following instead: https://github.com/Pushwoosh/phonegap-cordova-push-notifications
And then did the same procedure for importing the plugins. I dragged it to the "Plugins" folder on my Xcode project, then next is I added the "AdSupport" framework on "Build Phases>Link Binary With Libraries (because it wasn't there and it is generating an error). Then there is still an error:
"The current deployment target does not support automated __weak references"
so I followed the instructions on this thread: Error Message: ARC is required to compile Pushwoosh SDK
I followed the rest of the tutorial about implementing pushwoosh on my app. And it's working now. So, basically I just got stuck on installing the plugin.
Lesson: Install plugins using the CLI. :)