swiftobjective-clinker-errorsios18xcode16

Unable Run/Build/Archive iOS app in Xcode 16


I have upgraded to Xcode 16.0 recently. I encountered the following error when building my project in iOS physical devices.

I am not sure how to resolve this issue and would appreciate any help.

Here is the error message

Assertion failed: ((ct == Atom::ContentType::objcConst) || (ct == Atom::ContentType::objcData) || (ct == Atom::ContentType::constData) || (ct == Atom::ContentType::constText)), function ObjCClassReadOnlyDataRef, file Atom.cpp, line 3022.


Linker command failed with exit code 1 (use -v to see invocation)

Note : Same codebase is building successfully in XCode 15.

I tried to debug and find more information about this error. But I couldn't find much information about it.


Solution

  • You can add an -ld64 flag to other linker flags (More info https://developer.apple.com/documentation/xcode-release-notes/xcode-15-release-notes#Linking)

    Build Settings