我正在尝试更新Sphero PhoneGap plugin以使用最新的Cordova 3.4.1和XCode 5.1。
如果我在XCode中运行它,构建工作正常。在Build Settings中,我指定了#34; Valid Architectures"只是armv7
和armv7s
。
但如果我在命令行上执行cordova build --device ios
,那么我得到:
Running command: /Users/peteshau/dev/src/pearson/prototypes/robots-sphero/phonegap-test/platforms/ios/cordova/build --device
Build settings from command line:
ARCHS = armv7 armv7s arm64
CONFIGURATION_BUILD_DIR = /Users/peteshau/dev/src/pearson/prototypes/robots-sphero/phonegap-test/platforms/ios/build/device
SDKROOT = iphoneos7.1
VALID_ARCHS = armv7 armv7s arm64
...
ld: warning: ignoring file RobotsSphero/Plugins/com.orbotix.sphero.SpheroPlugin/RobotKit.framework/RobotKit, missing required architecture arm64 in file RobotsSphero/Plugins/com.orbotix.sphero.SpheroPlugin/RobotKit.framework/RobotKit (2 slices)
Undefined symbols for architecture arm64:
"_OBJC_CLASS_$_RKRobotProvider", referenced from:
objc-class-ref in spheroGap.o
"_OBJC_CLASS_$_RKRawMotorValuesCommand", referenced from:
objc-class-ref in spheroGap.o
"_OBJC_CLASS_$_RKPingCommand", referenced from:
objc-class-ref in spheroGap.o
"_OBJC_CLASS_$_RKStabilizationCommand", referenced from:
objc-class-ref in spheroGap.o
"_OBJC_CLASS_$_RKRollCommand", referenced from:
objc-class-ref in spheroGap.o
"_OBJC_CLASS_$_RKCalibrateCommand", referenced from:
objc-class-ref in spheroGap.o
"_OBJC_CLASS_$_RKBackLEDOutputCommand", referenced from:
objc-class-ref in spheroGap.o
"_OBJC_CLASS_$_RKGoToSleepCommand", referenced from:
objc-class-ref in spheroGap.o
"_OBJC_CLASS_$_RKRGBLEDOutputCommand", referenced from:
objc-class-ref in spheroGap.o
"_RKDeviceConnectionOnlineNotification", referenced from:
-[spheroGap setupRobot] in spheroGap.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
** BUILD FAILED **
(与cordova run --device
相同的错误,无法启动)。
我正在尝试为运行iOS 7.1的iPhone 5S构建它。
根据我的有限理解(我对iOS开发非常不熟悉),看起来构建设置中指定的Valid Architectures限制被cordova忽略了吗?我有没有办法告诉它省略arm64
所以我可以让它运行?
(如果相关,本机" RobotKit"框架似乎需要Deployment Target being set to 6.0和各种Linker flags to be set。从命令行输出,它似乎使用指定的链接器标记OK)。
答案 0 :(得分:0)
这是一个确认的"缺陷"科尔多瓦:
https://issues.apache.org/jira/browse/CB-6716
我现在能够绕过它,通过更改"仅构建活动架构"到"是"。