storageType is 'SQLite' but no CBL_SQLiteStorage class found



I am using the newest couch base lite sdk (1.4) for iOS. After implementing my first lines to create a database, I get the following error:

  • WARNING: Upgrade skipped: Database upgrading class is not present. {at -[CBLManager upgradeOldDatabaseFiles]:361}
  • WARNING: storageType is ‘SQLite’ but no CBL_SQLiteStorage class found; make sure -ObjC is in Other Linker Flags in Build Settings {at -[CBLDatabase(Internal) openWithOptions:error:]:191}
  • Can not create or get database! Error Domain=CBLHTTP Code=406 “Can’t open database in that storage format” UserInfo={NSLocalizedFailureReason=Can’t open database in that storage format, NSLocalizedDescription=Can’t open database in that storage format}

If I add the -ObjC flag into other linker flags I get “linker command failed with exit code 1”, so not that helpful.

I am currently pretty much out of ideas how to fix this issue. Maybe someone can help me out? I am using Xcode8.3.3 with Qt5.8. So maybe there is a cross platform issue?


This sounds similar to this issue. You might check that to see if the discussion provides any help.

Offhand it does sound like a possible cross-platform issue. The thread I mentioned can show you how to check that CBL_SQLiteStorage is installed as expected. If it is, then it seems likely an issue with linker flags propagating properly. Can you get a log of the commands executed during build?


You do need to add that flag. Make sure you capitalized it correctly. If you still get that error, go into the build logs to find what the actual linker error is (Xcode sucks at actually reporting the text of a linker error) and post it here, and we’ll try to figure it out.


add -lc++ with -ObjC in other linker flag works for me.


Yes, or add libc++ to the libraries your target links with in the Build Phases tab.

(@bdiehm, that’s probably the source of your error too — the build log is probably reporting missing symbols for C++ library functions.)