I use Visual Studio 2012 for a typical LOB app. This app has DAL, BLL and UI layers.
All projects, excepts the Sqlite, are based on Portable Class Library (PCL), so I can compile once and they work for all platforms.
However the database is Sqlite. Sqlite uses native code, so I need to deploy a package for each platform.
For example, when I need to deploy for ARM processors, I need to recompile all projects (more than 20) for ARM because Sqlite is placed in the lower layer. Most of projects depends directly or indirectly of the DAL, where Sqlite is placed.
Which would be the best approach to solve this scenario?
Thank you
As soon as you include a native library in your app, you need to build a separate package for each platform, so that each one includes the right library for the platform.
If you’re not already using SQLite for Windows Runtime Visual Studio extension, you should. It adds SQLite as an extension to your add reference dialog. If you add it to your project from there, the native library for the right project will be automatically included every time you make a build.
To access the native library from .NET you can use sqlite-net which is platform independent.
Since you’re using PCL, it’s possible that you’re not writing your app only for WinRT. In this case the answer might not be totally applicable but I’d need more information to give you a more specific advice.