且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

iOS8 phonegap cordova网络信息应用崩溃

更新时间:2021-10-30 07:57:50

看起来我发现了问题。一旦您在XCode项目(Project-> Build Settings)中禁用了ARC(自动引用计数),Network-Information Plugin就会导致崩溃。所以我通过将选项设置为YES(在Target& Project中)来修复它。

It looks like I found the problem. Once you have ARC (Automatic Reference Counting) disabled in your XCode Project (Project->Build Settings) the Network-Information Plugin seems to cause a crash. So I fixed it by setting the option back to YES (in both Target & Project).

但是在我的例子中,我有一些类会导致构建失败ARC是。因此,我在Project-> Build Phases-> Compile Sources中为每个类添加了一个标志 -fno-objc-arc

But in my case I had some classes which causes the build to fail with ARC YES. Therefore I added a flag -fno-objc-arc for each those classes in Project->Build Phases->Compile Sources.