Swiftgram / TDLibKit

Native Swift wrapper for Telegram's TDLib. Available on iOS, macOS, watchOS, tvOS and visionOS.
MIT License
106 stars 23 forks source link

Conflict with SQLite library in TDLibKit and Googles Firebase (FCM)' SQLite library #9

Closed k0ry closed 2 years ago

k0ry commented 2 years ago

Hello, on iOS projects there is conflict with SQLite library in TDLibKit and Googles Firebase (FCM)' SQLite library, causing runtime error: onError Error(code: 400, message: "[query:SELECT sqlcipher_export('encrypted')] to database " /Library/Caches/tdlib/db.sqlite" failed: no such function: sqlcipher_export")

How to resolve this issue?

Kylmakalle commented 2 years ago

Hello. Please provide an example project or exact libraries versions you're experiencing conflicts with.

k0ry commented 2 years ago

https://github.com/k0ry/TelegramTest

Kylmakalle commented 2 years ago

I've successfully fixed that moving from Pods to SPM dependencies for your Firebase packages. https://firebase.google.com/docs/ios/installation-methods

As for this issue, you can't link both sqlite-based libs together with TDLib in the same binary (application in our case). https://github.com/tdlib/td/issues/1815#issuecomment-1006842919

Feel free to comment this issue in case you will find out something else.

k0ry commented 2 years ago

Thank you for your support!