I have a custom iOS plugin that is built with modules enabled, in order to use the native Photos Framework introduced in iOS 8.x:
https://developer.apple.com/library/ios/documentation/Photos/Reference/Photos_Framework/
This works just fine in Xcode. But it does require a specific build setting in Xcode to Enable Modules (C and Objective-C). See also:
http://stackoverflow.com/a/25883210/1039247
Importing this custom plugin in AppBuilder (VisualStudio extension) also works just fine. The problem is, upon building it with AppBuilder, for example when trying to deploy it to a locally attached device, we get the following error:
Error: [xcode-build] Compile /tmp/builds/WVBfZ76xiIaDb97mpk/app/Cordova370/Plugins/com.acme.sandbox/SOSPicker.m: In file included from /tmp/builds/WVBfZ76xiIaDb97mpk/app/Cordova370/Plugins/com.acme.sandbox/SOSPicker.m:12:
/tmp/builds/WVBfZ76xiIaDb97mpk/app/Cordova370/Plugins/com.acme.sandbox/GMsandboxController.h:9:1: error: use of '@import' when modules are disabled
/tmp/builds/WVBfZ76xiIaDb97mpk/app/Cordova370/Plugins/com.acme.sandbox/GMsandboxController.h:10:1: error: use of '@import' when modules are disabled
In file included from /tmp/builds/WVBfZ76xiIaDb97mpk/app/Cordova370/Plugins/com.acme.sandbox/SOSPicker.m:12:
In file included from /tmp/builds/WVBfZ76xiIaDb97mpk/app/Cordova370/Plugins/com.acme.sandbox/GMsandboxController.h:12:
/tmp/builds/WVBfZ76xiIaDb97mpk/app/Cordova370/Plugins/com.acme.sandbox/GMFetchItem.h:11:1: error: use of '@import' when modules are disabled
In file included from /tmp/builds/WVBfZ76xiIaDb97mpk/app/Cordova370/Plugins/com.acme.sandbox/SOSPicker.m:12:
/tmp/builds/WVBfZ76xiIaDb97mpk/app/Cordova370/Plugins/com.acme.sandbox/GMsandboxController.h:84:22: error: expected a type
/tmp/builds/WVBfZ76xiIaDb97mpk/app/Cordova370/Plugins/com.acme.sandbox/GMsandboxController.h:85:24: error: expected a type
/tmp/builds/WVBfZ76xiIaDb97mpk/app/Cordova370/Plugins/com.acme.sandbox/GMsandboxController.h:138:83: error: expected a type
/tmp/builds/WVBfZ76xiIaDb97mpk/app/Cordova370/Plugins/com.acme.sandbox/GMsandboxController.h:148:85: error: expected a type
/tmp/builds/WVBfZ76xiIaDb97mpk/app/Cordova370/Plugins/com.acme.sandbox/GMsandboxController.h:164:85: error: expected a type
/tmp/builds/WVBfZ76xiIaDb97mpk/app/Cordova370/Plugins/com.acme.sandbox/GMsandboxController.h:173:82: error: expected a type
/tmp/builds/WVBfZ76xiIaDb97mpk/app/Cordova370/Plugins/com.acme.sandbox/GMsandboxController.h:184:87: error: expected a type
/tmp/builds/WVBfZ76xiIaDb97mpk/app/Cordova370/Plugins/com.acme.sandbox/GMsandboxController.h:193:84: error: expected a type
/tmp/builds/WVBfZ76xiIaDb97mpk/app/Cordova370/Plugins/com.acme.sandbox/GMsandboxController.h:209:88: error: expected a type
/tmp/builds/WVBfZ76xiIaDb97mpk/app/Cordova370/Plugins/com.acme.sandbox/GMsandboxController.h:218:85: error: expected a type
/tmp/builds/WVBfZ76xiIaDb97mpk/app/Cordova370/Plugins/com.acme.sandbox/GMsandboxController.h:228:87: error: expected a type
Error: 'Build failed with error code 2'
So, the main error seems to be: **error: use of '@import' when modules are disabled**
In short, is there any way to set AppBuilder to configure AppBuilder to build with this specific setting ('Enable Modules') for iOS upon a cloud build? If not, are there any workarounds regarding this?
Thanks in advance.