I'm using SQLite.swift and SQLCipher via cocoapods.
I get the error ambiguous use of 'SQLITE_DETERMINISTIC' in the SQLite.swift file: Connection.swift fails at line 590. Snippet is show below.
var flags = SQLITE_UTF8
#if !os(Linux)
if deterministic {
flags |= SQLITE_DETERMINISTIC
}
#endif
I can fix this by unlocking the pod file and replace 'SQLITE_DETERMINISTIC' with 'SQLCipher.SQLITE_DETERMINISTIC' or 'SQLite.SQLITE_DETERMINISTIC'. But this is bad for lots of reasons.
Steps to reproduce:
Example Podfile:
use_frameworks!
target 'TestSQLite' do
pod 'SQLite.swift/SQLCipher', '~> 0.12.2' # with SQLCipher
end
Any help would be appreciated.
SQLite.swift version 0.12.2 and you did not specify SQLCipher version. Please check SQLCipher version which may be 4.3.0 in Podfile.lock file. In this case, set SQLCipher version to 4.2.0. Clean and build the project. It will work. You can update pods
pod 'SQLCipher', '~>4.2.0'
pod 'SQLite.swift/SQLCipher', '~>0.12.0'
Run following commands in command line
pod deintegrate
pod install
Thank you