keepass: 2.30 -> 2.31

Also replaces the keepass.patch with sed,
as the patch was having problems with newlines.
This commit is contained in:
Tomasz Kontusz
2016-01-29 21:19:59 +01:00
parent 71a4d36983
commit 16d9d3841f
2 changed files with 15 additions and 95 deletions
+15 -6
View File
@@ -8,19 +8,17 @@
# plugin derivations in the Nix store and nowhere else.
with builtins; buildDotnetPackage rec {
baseName = "keepass";
version = "2.30";
version = "2.31";
src = fetchurl {
url = "mirror://sourceforge/keepass/KeePass-${version}-Source.zip";
sha256 = "1r792cikgvzj4hrxiv7xd3gx2zmn16dbh4inj2zi6ny0gchkqg2a";
sha256 = "10bqxpq30gzfq2ip6dkmqlzzsh3bnfdb01jry5xhgxvlycq1lnsm";
};
sourceRoot = ".";
buildInputs = [ unzip makeWrapper ];
patches = [ ./keepass.patch ];
pluginLoadPathsPatch =
let outputLc = toString (add 8 (length plugins));
patchTemplate = readFile ./keepass-plugins.patch;
@@ -34,10 +32,21 @@ with builtins; buildDotnetPackage rec {
passAsFile = [ "pluginLoadPathsPatch" ];
postPatch = ''
patch --binary -p1 <$pluginLoadPathsPatchPath
sed -i 's/\r*$//' KeePass/Forms/MainForm.cs
patch -p1 <$pluginLoadPathsPatchPath
'';
preConfigure = "rm -rvf Build/*";
preConfigure = ''
rm -rvf Build/*
find . -name "*.sln" -print -exec sed -i 's/Format Version 10.00/Format Version 11.00/g' {} \;
find . -name "*.csproj" -print -exec sed -i '
s#ToolsVersion="3.5"#ToolsVersion="4.0"#g
s#<TargetFrameworkVersion>.*</TargetFrameworkVersion>##g
s#<PropertyGroup>#<PropertyGroup><TargetFrameworkVersion>v4.5</TargetFrameworkVersion>#g
s#<SignAssembly>.*$#<SignAssembly>false</SignAssembly>#g
s#<PostBuildEvent>.*sgen.exe.*$##
' {} \;
'';
desktopItem = makeDesktopItem {
name = "keepass";