apache / cordova-ios

Apache Cordova iOS
https://cordova.apache.org/
Apache License 2.0
2.15k stars 986 forks source link

Regression from 5.1.1 to 6.1.0 : Fail to compile CDVWKWebViewEngine.o to CDVWKWebViewEngine.m normal arm64 objective-c #996

Closed Pitouli closed 3 years ago

Pitouli commented 3 years ago

Bug Report

Problem

What is expected to happen?

My app should build

What does actually happen?

** ARCHIVE FAILED **

The following build commands failed:
        CompileC /Users/pitouli/Library/Developer/Xcode/DerivedData/MyApp-hcczzqafauzxokbhoszenxnbgkca/Build/Intermediates.noindex/ArchiveIntermediates/Kipinto/IntermediateBuildFilesPath/Kipinto.build/Release-iphoneos/MyApp.build/Objects-normal/arm64/CDVWKWebViewEngine.o /Users/pitouli/Documents/GIT/MyApp/cordova/platforms/ios/MyApp/Plugins/cordova-plugin-wkwebview-engine/CDVWKWebViewEngine.m normal arm64 objective-c com.apple.compilers.llvm.clang.1_0.compiler

Information

If I remove the plugin, then the installation succeeds. Or if I downgrade cordova-ios to 5.1.1; it succeeds (note: it fails on 6.0.0)

Command or Code

Run:

cordova create MyApp
cd MyApp
cordova plugin add cordova-plugin-wkwebview-engine --save
cordova platform add ios
cordova build ios

You should have signing errors. Open Xcode to parameter the correct provisioning profiles. And relaunch cordova build ios

You should observe the exact same error as above.

Note: my package looks like this:

{
  "name": "io.cordova.hellocordova",
  "displayName": "HelloCordova",
  "version": "1.0.0",
  "description": "A sample Apache Cordova application that responds to the deviceready event.",
  "main": "index.js",
  "scripts": {
    "test": "echo \"Error: no test specified\" && exit 1"
  },
  "keywords": [
    "ecosystem:cordova"
  ],
  "author": "Apache Cordova Team",
  "license": "Apache-2.0",
  "devDependencies": {
    "cordova-ios": "^6.1.1",
    "cordova-plugin-whitelist": "^1.3.4",
    "cordova-plugin-wkwebview-engine": "^1.2.1"
  },
  "cordova": {
    "plugins": {
      "cordova-plugin-whitelist": {},
      "cordova-plugin-wkwebview-engine": {}
    },
    "platforms": [
      "ios"
    ]
  }
}

Environment, Platform, Device

MacOS 10.15.6, XCode 12.0.1,

Version information

Cordova: Cordova CLI 10.0, Cordova-iOS 6.1.1,

Plugins: cordova-plugin-wkwebview-engine 1.2.1 "Cordova WKWebView Engine"

Checklist

I opened first a ticket on CDVWKWebViewEngine repository, but since its cordova-ios which became incompatible, I do not know which place is the best. So both. https://github.com/apache/cordova-plugin-wkwebview-engine/issues/177

dpogue commented 3 years ago

Remove cordova-plugin-wkwebview-engine, you do not need it with cordova-ios 6.x. It uses WKWebView automatically.