Failed to fetch platform cordova-ios@^5.0.0
Closed this issue · 7 comments
Step to reproduce:
git clone https://github.com/dpa99c/cordova-plugin-firebasex-test.git && cd cordova-plugin-firebasex-test
npm install
cordova platform add ios
I get
Using cordova-fetch for cordova-ios@^5.0.0
Failed to fetch platform cordova-ios@^5.0.0
Probably this is either a connection problem, or platform spec is incorrect.
Check your connection and platform name/version/URL.
Could not determine package name from output:
audited 176 packages in 7.404s
found 1 high severity vulnerability
run `npm audit fix` to fix them, or `npm audit` for details
After move
"devDependencies": {
"cordova-android": "^9.0.0",
"cordova-ios": "^6.1.1",
...
},
to
"dependencies": {
"cordova-android": "^9.0.0",
"cordova-ios": "^6.1.1",
...
},
success
Using cordova-fetch for cordova-ios@^6.1.1
Adding ios project...
Creating Cordova project for the iOS platform:
Path: platforms/ios
Package: uk.co.workingedge.firebase.test
Name: FirebaseTest
iOS project created with cordova-ios@6.1.1
Installing "cordova-plugin-customfcmreceiver" for ios
Discovered saved plugin "cordova-plugin-whitelist". Adding it to the project
Installing "cordova-plugin-whitelist" for ios
Adding cordova-plugin-whitelist to package.json
Discovered saved plugin "cordova-plugin-firebasex". Adding it to the project
Installing "cordova-plugin-firebasex" for ios
Ignoring unf_ext-0.0.7.6 because its extensions are not built. Try: gem pristine unf_ext --version 0.0.7.6
Running command: pod install --verbose
Ignoring unf_ext-0.0.7.6 because its extensions are not built. Try: gem pristine unf_ext --version 0.0.7.6
[!] The `FirebaseTest [Debug]` target overrides the `LD_RUNPATH_SEARCH_PATHS` build setting defined in `Pods/Target Support Files/Pods-FirebaseTest/Pods-FirebaseTest.debug.xcconfig'. This can lead to problems with the CocoaPods installation
[!] The `FirebaseTest [Release]` target overrides the `LD_RUNPATH_SEARCH_PATHS` build setting defined in `Pods/Target Support Files/Pods-FirebaseTest/Pods-FirebaseTest.release.xcconfig'. This can lead to problems with the CocoaPods installation
[!] Your project does not explicitly specify the CocoaPods master specs repo. Since CDN is now used as the default, you may safely remove it from your repos directory via `pod repo remove master`. To suppress this warning please add `warn_for_unused_master_specs_repo => false` to your Podfile.
Adding cordova-plugin-firebasex to package.json
Discovered saved plugin "cordova-custom-config". Adding it to the project
Installing "cordova-custom-config" for ios
Adding cordova-custom-config to package.json
Discovered saved plugin "cordova-plugin-dialogs". Adding it to the project
Installing "cordova-plugin-dialogs" for ios
Adding cordova-plugin-dialogs to package.json
Discovered saved plugin "cordova-plugin-enable-multidex". Adding it to the project
Installing "cordova-plugin-enable-multidex" for ios
Adding cordova-plugin-enable-multidex to package.json
Discovered saved plugin "cordova-plugin-androidx-adapter". Adding it to the project
Installing "cordova-plugin-androidx-adapter" for ios
Adding cordova-plugin-androidx-adapter to package.json
Discovered saved plugin "cordova-plugin-hello-c". Adding it to the project
Installing "cordova-plugin-hello-c" for ios
Adding cordova-plugin-hello-c to package.json
Overwriting existing resource file at platforms/ios/FirebaseTest/Resources/res/ios/sound/blackberry.caf
Overwriting existing resource file at platforms/ios/FirebaseTest/Resources/res/ios/sound/crystal.caf
Overwriting existing resource file at platforms/ios/FirebaseTest/Resources/res/ios/sound/msn.caf
Overwriting existing resource file at platforms/ios/FirebaseTest/Resources/res/ios/pn-actions.json
cordova-plugin-firebasex: Preparing Firebase on iOS
cordova-plugin-firebasex: Applied IOS_STRIP_DEBUG to Podfile
After
cordova run ios
I get
warning: The iOS Simulator deployment target 'IPHONEOS_DEPLOYMENT_TARGET' is set to 8.0, but the range of supported deployment target versions is 9.0 to 14.1.99. (in target 'FirebaseAuth' from project 'Pods')
warning: The iOS Simulator deployment target 'IPHONEOS_DEPLOYMENT_TARGET' is set to 8.0, but the range of supported deployment target versions is 9.0 to 14.1.99. (in target 'FirebaseABTesting' from project 'Pods')
warning: The iOS Simulator deployment target 'IPHONEOS_DEPLOYMENT_TARGET' is set to 8.0, but the range of supported deployment target versions is 9.0 to 14.1.99. (in target 'AppAuth' from project 'Pods')
** BUILD FAILED **
The following build commands failed:
PhaseScriptExecution [CP]\ Copy\ Pods\ Resources /Users/admin/Library/Developer/Xcode/DerivedData/FirebaseTest-hjhuhmzxnjwfcudxhrjwtesybxwd/Build/Intermediates.noindex/FirebaseTest.build/Debug-iphonesimulator/FirebaseTest.build/Script-206522D0329F347DF1501CAA.sh
(1 failure)
xcodebuild: Command failed with exit code 65
Then I add to Podfile:
post_install do |installer|
installer.pods_project.targets.each do |target|
target.build_configurations.each do |config|
config.build_settings['DEBUG_INFORMATION_FORMAT'] = 'dwarf'
end
target.build_configurations.each do |config|
if config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] == '8.0'
config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '9.0'
end
end
end
end
Run
pod repo update --verbose
pod install --verbose
cordova run ios
fix previous error but now I get
problem simular dpa99c/cordova-plugin-firebasex#326
InAppMessagingDisplayResources.bundle" not found. Run 'pod install' to update the copy resources script.
InAppMessagingDisplayResources.bundle" not found. Run 'pod install' to update the copy resources script.
Either build in Xcode or add the CLI version of the plugin:
cordova plugin rm cordova-plugin-firebasex --nosave && cordova plugin add cordova-plugin-firebasex@latest-cli
In my own project I get:
with 8.0.1 version
platforms/ios/Runner/Plugins/cordova-plugin-firebasex/FirebasePlugin.m:5:9: fatal error: 'Fabric/Fabric.h' file not found
#import <Fabric/Fabric.h>
with 11.0.1-cli version
platforms/ios/Runner/Plugins/cordova-plugin-firebasex/FirebasePlugin.h:4:9: fatal error: module 'FirebaseFirestore' not found
@import FirebaseFirestore;
I don't know what to do next.
with 8.0.1 version
don't use v8.0.1 - it's out-of-date and Fabric is no longer supported.
with 11.0.1-cli version
looks to be a problem with the Firestore module, could be due to a Cocoapods issue - see here for some advice.
However I'm closing this issue as you can now build+run this example project.