Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hybrid application build fails with xcodebuild: Command failed with exit code 65 #68

Open
GerthH opened this issue Oct 8, 2020 · 4 comments

Comments

@GerthH
Copy link

GerthH commented Oct 8, 2020

Following "Getting started" for a Hybrid IOS Mobile Application with:
MacOS 10.14.6
Xcode 11.3.1
ios-deploy 1.11.2
node -v v12.19.0
ojet -v Oracle JET Command Line Interface, version: 9.1.0
cordova -v 10.0.0
ojet create navdraweriosapp --hybrid --template navdrawer --platforms=ios
cd navdraweriosapp
ojet build

Results in a build error:
...
Cordova compile finished.
Error: Error: Command failed: cordova compile ios --debug --emulator
** BUILD FAILED **

The following build commands failed:
CompileC /Users/g/Library/Developer/Xcode/DerivedData/navdraweriosapp-famhjphadfxkaofbvpcwuylrmank/Build/Intermediates.noindex/navdraweriosapp.build/Debug-iphonesimulator/navdraweriosapp.build/Objects-normal/x86_64/CDVWKWebViewEngine.o /Work/JET/navdraweriosapp/hybrid/platforms/ios/navdraweriosapp/Plugins/cordova-plugin-wkwebview-engine/CDVWKWebViewEngine.m normal x86_64 objective-c com.apple.compilers.llvm.clang.1_0.compiler
(1 failure)
xcodebuild: Command failed with exit code 65

How can I correct this ?

Regards / Gerth

@peppertech
Copy link
Member

Hi Gerth,

This appears to be an issue between Cordova and XCode itself. The JET tooling pulls Cordova directly off-the-shelf and uses it. We know that Cordova 9 and XCode 11 is working fine. You should contact the Cordova community and see if there are any known issues or workarounds that you can use.

@GerthH
Copy link
Author

GerthH commented Oct 9, 2020

Hi and thank you for your prompt reply.
Can you please share the versions of jet, cordova and xcode that has been tested to work together ?
I might be able to downgrade my combination.
Regards / Gerth

@peppertech
Copy link
Member

peppertech commented Oct 9, 2020 via email

@GerthH
Copy link
Author

GerthH commented Oct 10, 2020

Thank you for your confirmation.
Plugin cordova-plugin-wkwebview-engine is the cause of the problem when using Cordova v6+.

The cordova-plugin-wkwebview-engine plugin is included in the hybrid plugins folder at every run of "ojet create --hybrid ...".
Is there a way to prevent Oracle JET from including this plugin in the generated hybrid structure to avoid my workaround explained below ?

Regards / Gerth
Details:

.../JET/navbarisoapp/hybrid/platforms/ios/navbarisoapp/Plugins/cordova-plugin-wkwebview-engine/CDVWKWebViewEngine.m:104:80: error: property 'userAgent' not found on object of type 'CDVViewController *'

"Cordova-ios@6 has wkwebview built in making this plugin obsolete."
Confirmation found here:
apache/cordova-plugin-wkwebview-engine#142

This plugin is part of the hybrid folder at every "ojet create --- --hybrid ...".

Workaround example so far (for my versions stated at the top; Cordova 10.0.0 etc...):

$ ojet create iosapp --template navbar --hybrid --platforms=ios
$ cd iosapp/hybrid
$ cordova plugin rm cordova-plugin-wkwebview-engine
6.0.0
Uninstalling cordova-plugin-wkwebview-engine from browser
Uninstalling cordova-plugin-wkwebview-engine from ios
Removing "cordova-plugin-wkwebview-engine"
Removing plugin cordova-plugin-wkwebview-engine from config.xml file...
Removing cordova-plugin-wkwebview-engine from package.json
$ cd ..
$ ojet build
...
** BUILD SUCCEEDED **

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants