科尔多瓦:在没有"-all_load"的情况下进行构建 [英] Cordova: Build Without "-all_load"

查看:41
本文介绍了科尔多瓦:在没有"-all_load"的情况下进行构建的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在使用Cordova和本机SDK附带的第三方插件构建iOS应用时遇到问题.科尔多瓦要求使用其他SDK不满意的链接器标记"-all_load".

I am having an issue while building an iOS app with Cordova and a third-party plugin that ships with a native SDK. Cordova requires Linker Flag "-all_load" which other SDK is not happy about.

我阅读了有关"-all_load"标志的帖子:

I read this post about "-all_load" flag: Alternative for all_load in XCode's Other Linker Flags sounds like I might be able to use "-force_load" instead and specify the "object file" that Cordova wants.

我对Cordova的内部知识了解不多.有谁遇到过同样的问题,并且能够使用"force_load"成功编译Cordova吗?您能否提供特定于 Cordova的"force_load"语法?

I do not know much about the Cordova's internals. Has anyone had the same problem and was successfully able to compile Cordova with "force_load"? Could you provide your Cordova specific "force_load" syntax?

推荐答案

此处的问题是,包含类别的库无法在早期版本的Xcode中正确加载.从4.6开始,它们应该正在加载,并且您应该只能使用链接器标志"-ObjC",该标志告诉链接器检查此类库.

The problem here is that libraries containing categories did not properly load in earlier versions of Xcode. As of 4.6 they should be loading, and you should be able to just use the linker flag "-ObjC", which tells the linker to examine the libraries for such things.

如果由于某种原因-ObjC标志不起作用,则强制加载的语法为"

If for some reason the -ObjC flag does not work, the syntax for the force load is"

-force_load $(BUILT_PRODUCTS_DIR)/libxyz.a

这篇关于科尔多瓦:在没有"-all_load"的情况下进行构建的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆