swift-package-managersqlite.swift

How Can I enable FTS5 support in SQLite.swift using the Swift Package Manager


I have a project that is built using SPM and in it I use the SQLite.swift library (src). In my Package.swift file I have the following dependency:

let package = Package(
...
  dependencies: [
    .package(url: "https://github.com/stephencelis/SQLite.swift.git", from: "0.14.1")
  ],
...
)

As per the documentation, however by default SQLite.swift only uses

the most recent version of SQLite without any extras

There is a CocoaPods example of adding FTS5 support but I can't find anyone who is using this with SPM, is there an official way?


Solution

  • See the answer here - it explains why the vanilla SPM install does not add these extras: How to enable FTS5 in GRDB.swift using SPM?