Software Archive
Read-only legacy content
17061 Discussions

Build error with some cordova plugins

Santtu_I_
Beginner
385 Views

Hello,

I am trying to get monetization working for my game, but none of the plugins that are needed to display reward videos on a device are building for ios.

Here is an example with just the SDK sample XDK project loaded.

XDK says that the build failed and I need to check the build log. In the build log this is what I find:

...
In file included from .../SampleApp/platforms/ios/SampleApp/Plugins/com.apptracker.
phonegap.ios/AppTrackerPlugin.m:9:SampleApp/Plugins/com.apptracker.phonegap.
ios/AppTrackerPlugin.h:11:9: fatal error: 'AppTracker/AppTracker.h' file not found
#import <AppTracker/AppTracker.h>
        ^
1 error generated.
...

The problem is the same with multiple plugins like Heyzap, Chartboost and Leadbolt. It can't find a <plugin-name/plugin-name.h> to import.

I have been searching google for similar problems, but there are none.
Any suggestions on how to get around this problem?

br,
Santtu I.

0 Kudos
3 Replies
Swati_S_Intel1
Employee
385 Views

Are you including the plugins through the Plugin Manager on the Projects tab? If not, include your plugins as third-party plugins. Also, if your plugins have gradle script it won't work, please see this post for details on how to remove gradle dependencies in your plugin.

https://software.intel.com/en-us/forums/intel-xdk/topic/629398. If none of the above apply to your plugins, please attach the full build log.

0 Kudos
Santtu_I_
Beginner
385 Views

Hi,

I have imported the plugin as third party from the cordova repository, "heyzap-cordova".

Here is the build log:

Build Log

  • Building a Cordova 5.4.1 application.
  • Using platform cordova-ios 4.0.1.
  • The application name is "Runehunt"
  • The package name is "com.runehunt"
  • Plugin "cordova-plugin-statusbar" (2.1.0) installed.
  • Plugin "cordova-plugin-device" (1.1.1) installed.
  • Plugin "cordova-plugin-splashscreen" (3.2.0) installed.
  • Plugin "intel.xdk.device" (3.0.1) installed.
  • Plugin "intel.xdk.player" (1.2.3) installed.
  • Plugin "cordova-plugin-uniquedeviceid" (1.3.2) installed.
  • Plugin "heyzap-cordova" (1.0.0) installed.
  • Targeting iOS version 9.2.
  • Error: A build error occurred. Check the build log.

The full log:  Here

0 Kudos
Swati_S_Intel1
Employee
385 Views

I tried building an app with your plugins "uniquedeviceid" and "heyzap", and the app builds fine. When you include the plugins as third-party plugins, in the Plugin Source try to provide the Github Repo URL of the plugin (not the Cordova Plugin Registry),  like this https://github.com/Paldom/UniqueDeviceID.

0 Kudos
Reply