I have an interesting (read: frustrating) situation in which I have two
.NET (C#) solutions which share some common projects. One of this
encapsulates our data access layer, and that is using System.Data.SQLite
version 1.0.82.0.

They are all running .NET 4.5, C# 2012, Debug, AnyCPU mode, and the unit
tests look identically configured, both on the hard drive and logically in
their respective solution trees. I used NuGet to install SQLite in both
solutions, so they each have their own copy in their respective /packages
directory.

So, to the naked eye, they seem identical. However, one solutions' unit
tests run absolutely fine, and the other one throws the error in the
subject of this email. Both are pulling in the common data layer project
which is the one that depends on SQLite. both have the following in the
Debug\bin directory:

x64\ (folder with 64 bit version of SQLite.Interop.dll in it)
x86\ (folder with 32 bit version of SQLite.Interop.dll in it)

... rest of the binaries required

I tried configuring all projects in the problem solution to Debug, x86, and
I even tried dropping the 32-bit version of the SQLite.Interop.dll into the
bin directory of the unit tests... and STILL I get this error.

I saw on post, a couple of google searches ago, that indicated perhaps the
version of the MS runtime DLLs might be the issue. Is it possible that one
of my projects has a "newer" version of System.Data.SQLite that was
compiled against a "newer" version of the MS C++ runtime dlls, even though
they have the same version (1.0.82.0)? (I have not upgraded to the latest
MS C++ runtime DLLs in my 2012 project, for all kinds of reasons that have
to do with some of our own C/C++ dependencies in native sub-projects.)

How should I troubleshoot this?

And in general how does SQLite work in "AnyCPU" mode if it needs
SQLite.Interop.dll to run, and there are precisely two mutually exclusive
versions of it -- 32 and 64 bit?

-- 
*Bob Calco*
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to