LoginSignup
4
5

More than 3 years have passed since last update.

dyld: Library not loaded: @rpath/Realm.framework/Realm

Last updated at Posted at 2020-02-08

概要

Xcode 11.3.1 になってからなのか、iOS 13.3.1 になってからなのか不明だが、実機の場合になぜか下記のエラーが出るようになった。(シミュレーターはOK)

dyld: Library not loaded: @rpath/Realm.framework/Realm

下記を参考に Podfile を変更して動くようになりましたが、あまり理解できていないのでやる方は自己責任でお願いします。バグなのかは不明ですが、Apple Developer Program に登録していない場合になるみたいです。

2020/03/11 追記

上記リンクを再度確認してみたところ、ベータで修正されているようですので13.4がリリースされれば解消しそうですね。

Can confirm, apps containing embedded frameworks installed with free Apple IDs are now working for me on iOS 13.4 beta 3 😄 Hopefully it stays fixed for GM!
確認できます。無料のApple IDでインストールされた組み込みフレームワークを含むアプリは、iOS 13.4 beta 3で動作します。 😄 うまくいけば、それはGMのために固定されたままです!

対応策

  • use_frameworks! をコメントアウトして変わりに use_modular_headers! にして update。
# Uncomment the next line to define a global platform for your project
# platform :ios, '9.0'

target 'MyApp' do
  # Comment the next line if you don't want to use dynamic frameworks
  # use_frameworks!
  use_modular_headers!

  # Pods for MyApp
  pod 'RealmSwift'
end
  • プロジェクトファイルの Frameworks, Libraries, and Embedded Content にあるフレームワークを変更。
Pods_MyApp.framework
↓↓↓
libPods-MyApp.a
4
5
1

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
4
5