Skip to content

Commit

Permalink
Add wiki file describing steps required to compile libSQLite.Interop.…
Browse files Browse the repository at this point in the history
…so on Linux
  • Loading branch information
alchemistmatt committed Jun 24, 2019
1 parent a3b56a9 commit 8c3b460
Showing 1 changed file with 41 additions and 0 deletions.
41 changes: 41 additions & 0 deletions System.Data.SQLite_Compilation_Steps_Linux.wiki
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
=== System.Data.SQLite ===

System.Data.SQLite DLLs in the x86 and x64 directories are compiled against Windows and thus will not work on Linux.
To use System.Data.SQLite on Linux, compile the .so file using the following steps:

1) Download the latest sqlite-netFx-full-source from https://system.data.sqlite.org/index.html/doc/trunk/www/downloads.wiki
* Specifically https://system.data.sqlite.org/downloads/1.0.108.0/sqlite-netFx-full-source-1.0.108.0.zip
2) Transfer to the Linux server, storing in <code>/home/username/System.Data.SQLite</code>

3) Extract the files using <code>unzip sqlite-netFx-full-source-1.0.108.0.zip</code>

4) If necessary, install gcc and related tools
<pre>
#Ubuntu:
sudo apt-get update
sudo apt-get install build-essential

#CentOS, either:
sudo yum install gcc gcc-c++ make openssl-devel

#or this (which includes even more tools)
sudo yum groupinstall 'Development Tools'
</pre>

5) Build the library
<pre>cd /home/username/System.Data.SQLite
cd Setup
chmod +x compile-interop-assembly-release.sh
./compile-interop-assembly-release.sh
</pre>

6) Look for the .so file named <code>libSQLite.Interop.so</code> and remove the execute permission (execute bit not needed)
<pre>cd ../bin/2013/Release/bin
chymod -x libSQLite.Interop.so
</pre>

7) Copy libSQLite.Interop.so to the directory where your Mono/.NET application's binaries reside (not the x64 or x86 subdirectories containing SQLite.Interop.dll). For example:
<pre>cp libSQLite.Interop.so /opt/DMS_Programs/AScore</pre>

Note that the version of System.Data.SQLite.dll in that directory must be 1.0.108 if the .so file was compiled using 1.0.108 source.

0 comments on commit 8c3b460

Please sign in to comment.