IOS cocoapods - how to add libsqlite3.dylib

I would like to include the iOS framework for libsqlite3.dylib as the framework inside cocoapod. In my .podspec file, I have a line like this:

spec.framework = 'libsqlite3.dylib' 

When I run the pod installation, it installs fine, but there is an error during the build.

  framework not found libsqlite3.dylib 

I can manually add the library by searching for it under Phase Assembling> Linking Binaries to Libraries> +. However, then I will have to comment out my podspec line for the framework to make the errors go away. I would really like this work to work using cocoapods without a manual step.

... so I assume that I am doing something wrong with the way I installed the framework in the podspec file.

+5
source share
1 answer

"libsqlite3.dylib" is a dynamic library, not a framework. To include libraries in your Podspec you should simply use:

 spec.library = 'sqlite3' 
+6
source

Source: https://habr.com/ru/post/1216215/


All Articles