[smuxi/vs_love] Common: copy win32 libraries to build directory
- From: Mirco M. M. Bauer <mmmbauer src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [smuxi/vs_love] Common: copy win32 libraries to build directory
- Date: Tue, 3 Nov 2015 21:50:16 +0000 (UTC)
commit 6326543e54d0d34ef05c4d572369ea97e2630777
Author: Mirco Bauer <meebey meebey net>
Date: Tue Nov 3 22:42:09 2015 +0100
Common: copy win32 libraries to build directory
The native libraries in lib/win32/ are needed after the build else it will try
to load the libraries from the system and the versions probably don't match.
This actually happened with the SQLite library from Mono 4.x leading to an
obscure error like this:
Exception Type:
Mono.Data.Sqlite.SqliteException
Exception Message:
File opened that is not a database file
file is encrypted or is not a database
Exception StackTrace:
at Mono.Data.Sqlite.SQLite3.Prepare (Mono.Data.Sqlite.SqliteConnection cnn, System.String strSql,
Mono.Data.Sqlite.SqliteStatement previous, UInt32 timeoutMS, System.String& strRemain) [0x0022a] in
C:\buildroot\release\repos\mono\mcs\class\Mono.Data.Sqlite\Mono.Data.Sqlite_2.0\SQLite3.cs:343
at Mono.Data.Sqlite.SqliteCommand.BuildNextCommand () [0x00019] in
C:\buildroot\release\repos\mono\mcs\class\Mono.Data.Sqlite\Mono.Data.Sqlite_2.0\SQLiteCommand.cs:230
The database wasn't damaged or anything but an incompatible SQLite library from
the system was loaded.
src/Common/Common.csproj | 23 ++++++++++++++++++++++-
src/smuxi.sln | 8 ++++----
2 files changed, 26 insertions(+), 5 deletions(-)
---
diff --git a/src/Common/Common.csproj b/src/Common/Common.csproj
index 93afcf4..8c2cf97 100644
--- a/src/Common/Common.csproj
+++ b/src/Common/Common.csproj
@@ -39,6 +39,21 @@
</Execution>
<DebugSymbols>true</DebugSymbols>
</PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug-Win32|AnyCPU' ">
+ <Optimize>false</Optimize>
+ <OutputPath>..\..\bin\debug</OutputPath>
+ <WarningLevel>4</WarningLevel>
+ <DebugSymbols>true</DebugSymbols>
+ <CheckForOverflowUnderflow>true</CheckForOverflowUnderflow>
+ <DefineConstants>DEBUG;TRACE;LOG4NET;NET_2_0;NDESK_OPTIONS</DefineConstants>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release-Win32|AnyCPU' ">
+ <Optimize>true</Optimize>
+ <OutputPath>..\..\bin\release</OutputPath>
+ <WarningLevel>4</WarningLevel>
+ <DebugSymbols>true</DebugSymbols>
+ <DefineConstants>TRACE;LOG4NET;NET_2_0;NDESK_OPTIONS</DefineConstants>
+ </PropertyGroup>
<ItemGroup>
<Compile Include="AssemblyInfo.cs" />
<Compile Include="ITraceable.cs" />
@@ -87,4 +102,10 @@
</Properties>
</MonoDevelop>
</ProjectExtensions>
-</Project>
\ No newline at end of file
+ <Target Name="AfterBuild">
+ <ItemGroup>
+ <LibWin32Items Include="$(SolutionDir)..\lib\win32\*" />
+ </ItemGroup>
+ <Copy Condition=" '$(Configuration)' == 'Debug-Win32' " DestinationFolder="$(OutputPath)"
SourceFiles="@(LibWin32Items)" SkipUnchangedFiles="true" />
+ </Target>
+</Project>
diff --git a/src/smuxi.sln b/src/smuxi.sln
index 387d827..3a959c0 100644
--- a/src/smuxi.sln
+++ b/src/smuxi.sln
@@ -225,12 +225,12 @@ Global
{600CD3BF-2ED2-4183-87F7-ADD78A968AE0}.Release-Win32|x86.Build.0 = Release|Any CPU
{73DEF91D-03FF-41E3-B2E1-3259AF247CA7}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{73DEF91D-03FF-41E3-B2E1-3259AF247CA7}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {73DEF91D-03FF-41E3-B2E1-3259AF247CA7}.Debug-Win32|x86.ActiveCfg = Debug|Any CPU
- {73DEF91D-03FF-41E3-B2E1-3259AF247CA7}.Debug-Win32|x86.Build.0 = Debug|Any CPU
+ {73DEF91D-03FF-41E3-B2E1-3259AF247CA7}.Debug-Win32|x86.ActiveCfg = Debug-Win32|Any CPU
+ {73DEF91D-03FF-41E3-B2E1-3259AF247CA7}.Debug-Win32|x86.Build.0 = Debug-Win32|Any CPU
{73DEF91D-03FF-41E3-B2E1-3259AF247CA7}.Release|Any CPU.ActiveCfg = Release|Any CPU
{73DEF91D-03FF-41E3-B2E1-3259AF247CA7}.Release|Any CPU.Build.0 = Release|Any CPU
- {73DEF91D-03FF-41E3-B2E1-3259AF247CA7}.Release-Win32|x86.ActiveCfg = Release|Any CPU
- {73DEF91D-03FF-41E3-B2E1-3259AF247CA7}.Release-Win32|x86.Build.0 = Release|Any CPU
+ {73DEF91D-03FF-41E3-B2E1-3259AF247CA7}.Release-Win32|x86.ActiveCfg = Release-Win32|Any CPU
+ {73DEF91D-03FF-41E3-B2E1-3259AF247CA7}.Release-Win32|x86.Build.0 = Release-Win32|Any CPU
{7964E3E4-1E98-4AE0-AF1B-1B940CDF0A99}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{7964E3E4-1E98-4AE0-AF1B-1B940CDF0A99}.Debug|Any CPU.Build.0 = Debug|Any CPU
{7964E3E4-1E98-4AE0-AF1B-1B940CDF0A99}.Debug-Win32|x86.ActiveCfg = Debug|Any CPU
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]