We have an app that we can build fine for Andriod on Ionic Pro but get the following errors when building for iOS.
We don’t have much for expierence building for iOS. Can anyone give me some hints?
Here are the error details
❌ duplicate symbol _OBJC_CLASS_$_CDVLogger in
> CDVLogger.o
> libCordova.a(CDVLogger.o)
❌ duplicate symbol _OBJC_METACLASS_$_CDVLogger in
> CDVLogger.o
> libCordova.a(CDVLogger.o)
❌ ld: 2 duplicate symbols for architecture armv7
❌ clang: error: linker command failed with exit code 1 (use -v to see invocation)
▸ Linking Appi4\
❌ duplicate symbol _OBJC_CLASS_$_CDVLogger in
> CDVLogger.o
> libCordova.a(CDVLogger.o)
❌ duplicate symbol _OBJC_METACLASS_$_CDVLogger in
> CDVLogger.o
> libCordova.a(CDVLogger.o)
❌ ld: 2 duplicate symbols for architecture arm64
❌ clang: error: linker command failed with exit code 1 (use -v to see invocation)
[23:07:50]: Exit status: 65
+---------------+-------------------------+
| Build environment |
+---------------+-------------------------+
| xcode_path | /Applications/Xcode.app |
| gym_version | 2.75.1 |
| export_method | development |
| sdk | iPhoneOS11.2.sdk |
+---------------+-------------------------+
[23:07:50]: ▸ duplicate symbol _OBJC_METACLASS_$_CDVLogger in:
[23:07:50]: ▸ /Users/ionic/Library/Developer/Xcode/DerivedData/Appi4_Spire-hgjmvadrxtzojzcjtqnycsknmszm/Build/Intermediates.noindex/ArchiveIntermediates/Appi4 Spire/IntermediateBuildFilesPath/Appi4 Spire.build/Release-iphoneos/Appi4 Spire.build/Objects-normal/arm64/CDVLogger.o
[23:07:50]: ▸ /Users/ionic/Library/Developer/Xcode/DerivedData/Appi4_Spire-hgjmvadrxtzojzcjtqnycsknmszm/Build/Intermediates.noindex/ArchiveIntermediates/Appi4 Spire/BuildProductsPath/Release-iphoneos/libCordova.a(CDVLogger.o)
[23:07:50]: ▸ ld: 2 duplicate symbols for architecture arm64
[23:07:50]: ▸ clang: error: linker command failed with exit code 1 (use -v to see invocation)
[23:07:50]:
[23:07:50]: ⬆️ Check out the few lines of raw `xcodebuild` output above for potential hints on how to solve this error
[23:07:50]: 📋 For the complete and more detailed error log, check the full log at:
[23:07:50]: 📋 /Users/ionic/Library/Logs/gym/Appi4 Spire-Appi4 Spire.log
[23:07:50]:
[23:07:50]: Your `export_method` in gym is defined as `development`
[23:07:50]: which might cause problems when signing your application
[23:07:50]: Are you sure want to build and export for development?
[23:07:50]: Please make sure to define the correct export methods when calling
[23:07:50]: gym in your Fastfile or from the command line
[23:07:50]:
[23:07:50]:
[23:07:50]: Looks like fastlane ran into a build/archive error with your project
[23:07:50]: It's hard to tell what's causing the error, so we wrote some guides on how
[23:07:50]: to troubleshoot build and signing issues: https://docs.fastlane.tools/codesigning/getting-started/
[23:07:50]: Before submitting an issue on GitHub, please follow the guide above and make
[23:07:50]: sure your project is set up correctly.
[23:07:50]: fastlane uses `xcodebuild` commands to generate your binary, you can see the
[23:07:50]: the full commands printed out in yellow in the above log.
[23:07:50]: Make sure to inspect the output above, as usually you'll find more error information there
[23:07:50]:
[23:07:50]: -------------------------
[23:07:50]: --- Step: upload_logs ---
[23:07:50]: -------------------------
[23:07:52]: ---------------------------
[23:07:52]: --- Step: shell command ---
[23:07:52]: ---------------------------
[23:07:52]: -----------------------------
[23:07:52]: --- Step: delete_keychain ---
[23:07:52]: -----------------------------
[23:07:52]: Error building the application - see the log above
+-------------------------------------+--------------------------------------+
| Lane Context |
+-------------------------------------+--------------------------------------+
| DEFAULT_PLATFORM | ios |
| PLATFORM_NAME | ios |
| LANE_NAME | ios package_build |
| DOWNLOAD_CERTS_CODESIGNING_IDENTITY | iPhone Developer: Gerhard Peters |
| | (CCGQ4ENNDL) |
| DOWNLOAD_CERTS_TEAM_ID | G2N23EKGTH |
| DOWNLOAD_CERTS_PROJECT_NAME | Appi4 Spire |
| DOWNLOAD_CERTS_CERT_PATH | /Users/ionic/builds/project-1/cert_ |
| | file.p12 |
| DOWNLOAD_CERTS_PROVISIONING_PATH | /Users/ionic/builds/project-1/provi |
| | sion_file.mobileprovision |
| SIGH_PROFILE_PATHS | ["/Users/ionic/builds/project-1/pro |
| | vision_file.mobileprovision"] |
+-------------------------------------+--------------------------------------+
[23:07:52]: Error building the application - see the log above
+------+------------------------+-------------+
| fastlane summary |
+------+------------------------+-------------+
| Step | Action | Time (in s) |
+------+------------------------+-------------+
| 1 | default_platform | 0 |
| 2 | build_summary | 1 |
| 3 | download_www | 4 |
| 4 | create_keychain | 0 |
| 5 | download_certs | 2 |
| 6 | import_certificate | 0 |
| 7 | npm install --quiet | 30 |
| 8 | cordova platform add | 11 |
| | ios --nofetch | |
| 9 | update_project_codesi | 0 |
| | gning | |
| 10 | update_project_provis | 0 |
| | ioning | |
| 💥 | gym | 82 |
| 12 | upload_logs | 1 |
| 13 | shell command | 0 |
| 14 | delete_keychain | 0 |
+------+------------------------+-------------+
[23:07:52]: fastlane finished with errors
\e[91mFailed to upload ipa to storage please retry your build.\e[0m
MAC Iteration 1
MAC verified OK
PKCS7 Encrypted data: pbeWithSHA1And40BitRC2-CBC, Iteration 2048
Certificate bag
PKCS7 Data
Shrouded Keybag: pbeWithSHA1And3-KeyTripleDES-CBC, Iteration 2048
[!] Error building the application - see the log above
Running after script...
$ clean-up
Cleaning up files...
Successful clean up
ERROR: Job failed: Process exited with: 1. Reason was: ()