0

Hello I am trying to replace all Pod dependencies in my project with Swift packages. Currently I have one blocker. There is one framework which only supports x86_64 architecture (its kotlin multiplatform) so I set the setting for excluded architecture to arm64 for debug, so far the project was set with this excluded architecture. But right now I am running into another problem where realmSwift, included as SP with version 10.32.3 it is throwing an error on import RealmSwift line Could not find module 'RealmSwift' for target 'x86_64-apple-ios-simulator'; found: arm64-apple-ios-simulator,... I cannot google anywhere which architecture version is currently supported by RealmSwift. Is there a way to get it working? Maybe installing lower realm version but I tried 10.5.0 which had the same problem? 10.5.0 was working fine as Pod dependency, but I need this one definitely as SP. It's strange that the same version of Realm supports different architectures for each dependency manager. I am running on M1 but the simulators are somehow running with excluded arm64 so. Slowly but running. Here is the build settings for architecture

The project is working when all dependencies are installed as cocoaPods and excluded arm64 architecture for debugging but I want to create my own framework distributed as SP and include it in this app and it needs to depend on some other frameworks which are already included in my project as Pods.

Hawkeye
  • 21
  • 3
  • Did you `pod deintegrate` before adding Realm via SPM? I just built a project on M1 and the SPM install went very smoothly. [Ream SPM Install](https://www.mongodb.com/docs/realm/sdk/swift/install/). Also, the question mentions Kotlin install - does it install correctly per the above and then doesn't when you integrate the Multiplatform? – Jay Nov 28 '22 at 19:35
  • Well I just resolved the issue with kotlin multiplatform framework, which now also supports Arm64 architecture. The problem was caused by realm SP when I had to exclude Arm64 because of the multiplatform framework. So now everything works well but I need to try to run it on Intel chip because its strange that the realm package refused to build for x86_64. That was the point of my question actually. Does the realm support x86_64 if it is included by SPM? – Hawkeye Dec 09 '22 at 11:18
  • I think I addressed that in my above comment as the project was built was SPM on and M1 (M2) so I believe the answer is yes it does. – Jay Dec 09 '22 at 17:34

0 Answers0