Open zakray opened 1 week ago
I've ran into this a few time while working on a silicon mac. If you're using pods one way to fix this is to add a post install script to your pod file that updates the architectures of each pod to exclude arm64 in debug mode. Not sure how to do it with swift package manager but if you move this dependency to a pod it should work fine.
pod deintegrate
post_install do |installer|
installer.pods_project.targets.each do |target|
target.build_configurations.each do |config|
if config.name == 'Debug'
config.build_settings['EXCLUDED_ARCHS[sdk=iphonesimulator*]'] = 'arm64'
end
end
end
end
pod install
Thanks for the suggestion, unfortunately I don't use CocoaPods
After installing DeviceKit, I'm unable to run my app via the simulator. I get "Build failed because DeviceKit.swiftmodule is not built for arm64, please try a run destination with a different architecture". After I got that error, a new simulator option with Rosetta appeared, but trying to build on that gave me a number of errors about "undefined symbol".
It does work fine on a real device.
Apologies if this is something obvious I'm missing, I don't have a lot of experience with swift packages. This is running latest macOS with Xcode 16 beta on an M2 Mac.