I am trying to use the SQLCipher IOS integration according to SQLCipher Community Edition - iOS and macOS Tutorial - Zetetic. I am having issues with building the project.
I was able to reproduce this on any new project by simply changing “Compile Sources As” from “According to file type” in to “Objective-C++”. See Dropbox - SQLCypher-Test-Import.zip - Simplify your life.
I tried to change the flag to According to file type but I do have some Objective-C++ code and that seems to break → no longer able to see "#include ".
Did anyone have this issue and managed to solve it?
Thanks for your interest in SQLCipher. You need to leave the “Compile Sources As” build setting as “According to File Type” as sqlite3.c is a C Source type and must be compiled as such.
For any files that you’re including an Objective C++ reference in, you’ll need to change the file name to use a double .mm to make sure it’s compiled as Objective C++.
The example project you linked appears to be in Swift, One thing to note is:
You cannot import C++ code directly into Swift. Instead, create an Objective-C or C wrapper for C++ code.