realm-swift: dyld: missing symbol called in custom XCFramework with pod dependency

How frequently does the bug occur?

All the time

Description

Hi,

I’m trying package a custom xcframework with the RealmSwift pod dependency. After upgrading to the latest version (10.32.0), when I import my xcframework into a test app, I’m getting the following error : dyld[6505]: missing symbol called And it point that method : image

Any ideas on how to fix that?

Can you reproduce the bug?

Yes, always

Version

10.32.0

What SDK flavour are you using?

Local Database only

Are you using encryption?

No, not using encryption

Platform OS and version(s)

iOS 15.5

Build environment

Xcode version: 14.0.1 Dependency manager and version: Cocoapods 1.11.3

About this issue

  • Original URL
  • State: open
  • Created 2 years ago
  • Reactions: 6
  • Comments: 17 (1 by maintainers)

Commits related to this issue

Most upvoted comments

I have a similar issue of missing symbol when I run my app using a framework generated by me that depends on Realm (10.46.0 or any recent version).

I found a workaround to make it working that is based on using xcframeworks in modified podspec. So I took the podspecs for Realm and RealmSwift, modified them to depend on xcframeworks published by Realm as releases and put the podspecs in a repo. For the edited podspec I removed the dependency for source files and related stuff, and set

s.source                  = { :http => 'https://github.com/realm/realm-swift/releases/download/v10.46.0/Carthage.xcframework.zip' } # for both
s.vendored_frameworks  = 'core/realm-monorepo.xcframework', 'Realm.xcframework' # for Realm
s.vendored_frameworks  = 'RealmSwift.xcframework' # for RealmSwift

You can look at my repo. More can be optimized and I’m sure there are fields that can be removed, but it works at the moment.

Then the custom version must be specified where needed, so for each podspec depending on Realm I use s.dependency 'RealmSwift', '10.46.0-xcframework'.

In Podfile remember to add the source with the url to the specs.

same issue here

Hi @evnik I’m taking a look at this, and I’m able to reproduce. I also found out that the version that introduces the issue is 10.21.0. Now I have to check which commit causes the issue.