Hi, We have a project we are trying to get to work on the cloud build, It's building for Android fine, but iOS build throws this error. 5991: - (void)mainDisplayInitedstruct UnityRenderingSurface*)surface 5992: ▸ Compiling VuforiaNativeRendererController.mm 5993: ▸ Linking UnityFramework 5994: ⚠;️ ld: arm64 function not 4-byte aligned: _unwind_tester from /BUILD_PATH/simongala.rmitilp.rmit_ios/temp20200422-6642-2ttrwc/Libraries/libiPhone-lib.a(unwind_test_arm64.o) 5995: ❌; Undefined symbols for architecture arm64 5996: > Symbol: _UIImagePickerController_delegate 5997: > Referenced from: _C_UIImagePickerController_delegate_mF2CF548D5C1EADBF1BE48A0454B6BED7C90F5CB2 in Assembly-CSharp8.o 5998: ❌; ld: symbol(s) not found for architecture arm64 5999: ❌; clang: error: linker command failed with exit code 1 (use -v to see invocation) 6000: ** ARCHIVE FAILED ** 6001: The following build commands failed: 6002: Ld /BUILD_PATH/Library/Developer/Xcode/DerivedData/Unity-iPhone-ayjiyunnfffponeujwkgpuohtmnq/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/IntermediateBuildFilesPath/UninstalledProducts/iphoneos/UnityFramework.framework/UnityFramework normal arm64 6003: (1 failure) 6004: Exit status: 65 6005: Maybe the error shown is caused by using the wrong version of Xcode 6006: Found multiple versions of Xcode in '/APPLICATION_PATH/' 6007: Make sure you selected the right version for your project 6008: This build process was executed using '/APPLICATION_PATH/Xcode11_3_1.app' 6009: If you want to update your Xcode path, either 6010: - Specify the Xcode version in your Fastfile 6011: ▸ xcversion(version: "8.1") # Selects Xcode 8.1.0 6012: - Specify an absolute path to your Xcode installation in your Fastfile 6013: ▸ xcode_select "/APPLICATION_PATH/Xcode8.app" 6014: - Manually update the path using 6015: ▸ sudo xcode-select -s /APPLICATION_PATH/Xcode.app 6016: +-------------+-------------------------------+ 6017: | Build environment | 6018: +-------------+-------------------------------+ 6019: | xcode_path | /APPLICATION_PATH/Xcode11_3_1.app | 6020: | gym_version | 2.142.0 | 6021: | sdk | iPhoneOS13.2.sdk | 6022: +-------------+-------------------------------+ 6023: ▸ _UIImagePickerController_get_AllowsEditing_m26B1D42491543868E09346A3120F346015959AD9 in Assembly-CSharp8.o 6024: ▸ _C_UIImagePickerController_allowsEditing_m2F66ED57F1EA2D5EA971CC6568597F30FD2088EF in Assembly-CSharp8.o 6025: ▸ (maybe you meant: _C_UIImagePickerController_allowsEditing_m2F66ED57F1EA2D5EA971CC6568597F30FD2088EF) 6026: ▸ ld: symbol(s) not found for architecture arm64 We tried building it on a local Mac and it builds without any issues, Any help would be very helpful. Thanks
Did you find a solution to this issue? I am finding the same issue when building using xcodebuild in terminal however with XCode GUI there is no issue when archiving
Found the solution for me, the build steps (in a gitlab-ci runner) were running xcodebuild on the xcodeproj file when the build project in fact grew an xcworkspace file instead, most likely due to adding new dependencies to the project like firebase
this helps: https://answers.unity.com/questions/222478/how-do-i-automatically-include-a-framework-with-my.html
Update minimum iOS version to a newer version in "Unity --> Edit --> Project Settings --> Player --> iOS Settings --> Other Settings --> Target minimum iOS Version" (12.0 in my case) and fix Unity version "Unity Dashboard --> Cloud Build --> Config --> in iOS profile --> Basic Info Unity version" (2021.2.0b13 in my case). This fix my issue.