Me again.. I have been working on a few projects of late that require a .net application to work both on Windows and Linux. I found to my surprise that Mono has a bug under Windows that causes the following error when ran under .net 4.0/4.5.
Unhandled Exception: System.TypeLoadException: Inheritance security rules violated by type: 'Mono.Data.Sqlite.SqliteConnectionHandle'. Derived types must either match the security accessibility of the base type or be less accessible. at Mono.Data.Sqlite.SQLite3.Open(String strFilename, SQLiteOpenFlagsEnum flags, Int32 maxPoolSize, Boolean usePool) at Mono.Data.Sqlite.SqliteConnection.Open()
Anyway long story short, if you are trying to use Sqlite3 and the Mono.Data.Sqlite.dll, you may want to download this altered version with the bug fix included.
I have not done anything fancy, just downloaded the Mono source and recompiled the Mono.Data.Sqlite.dll with the correct assembly attributes to run under .net 4.0/4.5.
This is nothing new and is a known bug, but I thought I would share since I was not able to find a recompiled version online with the fix included.