add older keepass version
This commit is contained in:
parent
a079f66bdb
commit
9266d7a22b
4 changed files with 163 additions and 0 deletions
4
app-admin/keepass/Manifest
Normal file
4
app-admin/keepass/Manifest
Normal file
|
|
@ -0,0 +1,4 @@
|
||||||
|
AUX keepass-2.20-xsl-path-detection.patch 1596 SHA256 6b95ac5786824424781dc12bb031e22c5ec8cd91ab406231ae4b09de07f42c42 SHA512 6aa8ee88e0dcb09f2394432ea49953c582127a38c75bb86ce24e9f4f979b5dc673a534dac550793bcb3bc337aa218aa71edc22d79aa7eb6bde204cd6981f2976 WHIRLPOOL 62b0e8438195f7ebe7fa3136fb26b95723c55a6cc1e71f9586f95b27225bdf60e28a1b7f67abefda86ca05eeee237369e734f93b8f17c7b4b5b41e68cc1237bf
|
||||||
|
AUX keepass.xml 275 SHA256 14e15149e0b9177008cc1fb67e57ef83e2c8663846403dfdf2411c77ebb3ee3f SHA512 a6055604ff4ff9e905012b5f8448540ea3b3fa8527ce1fd247fe4e5329e6861e5e7a01ea5ed907c41c073d81ee02452392ea0b0d61bf1119dadd300911a450fb WHIRLPOOL d0ee272ae608241ca67a0a2d1365d37e19b86ce4a7baede55f7094f8b1b58671935a753fa3f9859777c0bef2ee47a36b418165e5e6c894bfa6e634f965abd57e
|
||||||
|
DIST KeePass-2.30-Source.zip 4767753 SHA256 4a3c3c217bc05b13bf903612b89a09b67ed1df68fdecd83324f2ef372313e9e4 SHA512 05404f273f6a7df33887b036aa0dba335124a7b2ae30b61957f8dc9c959cdd3342fdfa22a7d59ba5e9180f039fed5ecbac0a3154eb9d342a5a3a8a057d763182 WHIRLPOOL 4ddec9e592724b60724a2deaaf959dacc91f77d1ae97dd07af940f8efd882a008b4424ba68a4fcbd9ebe8d75c2b8a9a644ff7144ed593cfb3f0e361c0364a780
|
||||||
|
EBUILD keepass-2.30.ebuild 2811 SHA256 41c79bd446dbefd6bc848235ebf123a5d1795cb5708dfd806d6d015e112f9299 SHA512 709b29ba1b18d874cc9b409919f02ce9b0ea218ff8e866651b68d441ccb5dbce199d5708a8bd0852d81b31bd6f7ccdebf7fe9783a1a1a53b3ebd514b7d8f1cae WHIRLPOOL 90834bcd52cbd5ea1f08bfb91b822145c9d4b779778870dbe36eb29863aea45c7aba2730512a4e08d855dca43db6dc9ad73a97d8ee4883a50ec6265eb19d7c49
|
||||||
|
|
@ -0,0 +1,45 @@
|
||||||
|
KeePass looks for some resources (XSL files) in the executable directory,
|
||||||
|
however under UNIX system this not a good idea, so we look into the
|
||||||
|
CommonApplicationData SpecialFolder, which usually maps to "/usr/share/".
|
||||||
|
So the final search path should be "/usr/share/KeePass/XSL/".
|
||||||
|
|
||||||
|
diff --git a/KeePass/Forms/AboutForm.cs b/KeePass/Forms/AboutForm.cs
|
||||||
|
index 8a04c87..6083c00 100644
|
||||||
|
--- a/KeePass/Forms/AboutForm.cs
|
||||||
|
+++ b/KeePass/Forms/AboutForm.cs
|
||||||
|
@@ -31,9 +31,11 @@ using KeePass.UI;
|
||||||
|
using KeePass.Resources;
|
||||||
|
using KeePass.Util;
|
||||||
|
using KeePass.DataExchange;
|
||||||
|
+using KeePass.Native;
|
||||||
|
|
||||||
|
using KeePassLib;
|
||||||
|
using KeePassLib.Utility;
|
||||||
|
+using KeePassLib.Native;
|
||||||
|
|
||||||
|
namespace KeePass.Forms
|
||||||
|
{
|
||||||
|
@@ -92,8 +94,21 @@ namespace KeePass.Forms
|
||||||
|
m_lvComponents.Items.Add(lvi);
|
||||||
|
|
||||||
|
lvi = new ListViewItem(KPRes.XslStylesheetsKdbx);
|
||||||
|
- string strPath = WinUtil.GetExecutable();
|
||||||
|
- strPath = UrlUtil.GetFileDirectory(strPath, true, false);
|
||||||
|
+
|
||||||
|
+ string strPath;
|
||||||
|
+ if (NativeLib.IsUnix())
|
||||||
|
+ {
|
||||||
|
+ strPath = Environment.GetFolderPath(Environment.SpecialFolder.CommonApplicationData);
|
||||||
|
+ strPath = UrlUtil.EnsureTerminatingSeparator(strPath, false);
|
||||||
|
+ strPath += PwDefs.ShortProductName.ToLower();
|
||||||
|
+ strPath = UrlUtil.EnsureTerminatingSeparator(strPath, false);
|
||||||
|
+ }
|
||||||
|
+ else
|
||||||
|
+ {
|
||||||
|
+ strPath = WinUtil.GetExecutable();
|
||||||
|
+ strPath = UrlUtil.GetFileDirectory(strPath, true, false);
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
strPath += AppDefs.XslFilesDir;
|
||||||
|
strPath = UrlUtil.EnsureTerminatingSeparator(strPath, false);
|
||||||
|
bool bInstalled = File.Exists(strPath + AppDefs.XslFileHtmlLite);
|
||||||
9
app-admin/keepass/files/keepass.xml
Normal file
9
app-admin/keepass/files/keepass.xml
Normal file
|
|
@ -0,0 +1,9 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<mime-info xmlns='http://www.freedesktop.org/standards/shared-mime-info'>
|
||||||
|
<mime-type type="application/x-keepass2">
|
||||||
|
<comment>KeePass database</comment>
|
||||||
|
<glob pattern="*.kdbx"/>
|
||||||
|
<icon name="keepass" />
|
||||||
|
</mime-type>
|
||||||
|
</mime-info>
|
||||||
|
|
||||||
105
app-admin/keepass/keepass-2.30.ebuild
Normal file
105
app-admin/keepass/keepass-2.30.ebuild
Normal file
|
|
@ -0,0 +1,105 @@
|
||||||
|
# Copyright 1999-2015 Gentoo Foundation
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
# $Header: /var/cvsroot/gentoo-x86/app-admin/keepass/keepass-2.29.ebuild,v 1.1 2015/05/23 03:05:22 idella4 Exp $
|
||||||
|
|
||||||
|
EAPI=5
|
||||||
|
|
||||||
|
inherit eutils fdo-mime gnome2-utils mono-env multilib
|
||||||
|
|
||||||
|
MY_PN="KeePass"
|
||||||
|
DESCRIPTION="A free, open source, light-weight and easy-to-use password manager"
|
||||||
|
HOMEPAGE="http://keepass.info/"
|
||||||
|
SRC_URI="mirror://sourceforge/${PN}/${MY_PN}-${PV}-Source.zip"
|
||||||
|
|
||||||
|
LICENSE="GPL-2"
|
||||||
|
SLOT="0"
|
||||||
|
KEYWORDS="~amd64 ~x86"
|
||||||
|
IUSE="aot"
|
||||||
|
|
||||||
|
COMMON_DEPEND=">=dev-lang/mono-2.10.5"
|
||||||
|
RDEPEND="${COMMON_DEPEND}
|
||||||
|
dev-dotnet/libgdiplus[cairo]"
|
||||||
|
DEPEND="${COMMON_DEPEND}
|
||||||
|
app-arch/unzip"
|
||||||
|
|
||||||
|
S=${WORKDIR}
|
||||||
|
|
||||||
|
src_prepare() {
|
||||||
|
# Remove Windows-specific things
|
||||||
|
pushd Build > /dev/null || die
|
||||||
|
. PrepMonoDev.sh || die
|
||||||
|
popd > /dev/null || die
|
||||||
|
|
||||||
|
# KeePass looks for some XSL files in the same folder as the executable,
|
||||||
|
# we prefer to have it in /usr/share/KeePass
|
||||||
|
epatch "${FILESDIR}/${PN}-2.20-xsl-path-detection.patch"
|
||||||
|
}
|
||||||
|
|
||||||
|
src_compile() {
|
||||||
|
# Build with Release target
|
||||||
|
xbuild /target:KeePass /property:Configuration=Release || die
|
||||||
|
|
||||||
|
# Run Ahead Of Time compiler on the binary
|
||||||
|
if use aot; then
|
||||||
|
cp Ext/KeePass.exe.config Build/KeePass/Release/
|
||||||
|
mono --aot -O=all Build/KeePass/Release/KeePass.exe || die
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
src_install() {
|
||||||
|
# Wrapper script to launch mono
|
||||||
|
make_wrapper ${PN} "mono /usr/$(get_libdir)/${PN}/KeePass.exe"
|
||||||
|
|
||||||
|
# Some XSL files
|
||||||
|
insinto /usr/share/${PN}/XSL
|
||||||
|
doins Ext/XSL/*
|
||||||
|
|
||||||
|
insinto /usr/$(get_libdir)/${PN}/
|
||||||
|
exeinto /usr/$(get_libdir)/${PN}/
|
||||||
|
doins Ext/KeePass.exe.config
|
||||||
|
# Default configuration, simply says to use user-specific configuration
|
||||||
|
doins Ext/KeePass.config.xml
|
||||||
|
|
||||||
|
# The actual executable
|
||||||
|
doexe Build/KeePass/Release/KeePass.exe
|
||||||
|
|
||||||
|
# Copy the AOT compilation result
|
||||||
|
if use aot; then
|
||||||
|
doexe Build/KeePass/Release/KeePass.exe.so
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Prepare the icons
|
||||||
|
newicon -s 256 Ext/Icons/Finals/plockb.png "${PN}.png"
|
||||||
|
newicon -s 256 -t gnome -c mimetypes Ext/Icons/Finals/plockb.png "application-x-${PN}2.png"
|
||||||
|
|
||||||
|
# Create a desktop entry and associate it with the KeePass mime type
|
||||||
|
make_desktop_entry ${PN} ${MY_PN} ${PN} "System;Security" "MimeType=application/x-keepass2;"
|
||||||
|
|
||||||
|
# MIME descriptor for .kdbx files
|
||||||
|
insinto /usr/share/mime/packages/
|
||||||
|
doins "${FILESDIR}/${PN}.xml"
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_preinst() {
|
||||||
|
gnome2_icon_savelist
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_postinst() {
|
||||||
|
gnome2_icon_cache_update
|
||||||
|
fdo-mime_mime_database_update
|
||||||
|
fdo-mime_desktop_database_update
|
||||||
|
|
||||||
|
if ! has_version x11-misc/xdotool ; then
|
||||||
|
elog "Optional dependencies:"
|
||||||
|
elog " x11-misc/xdotool (enables autotype)"
|
||||||
|
fi
|
||||||
|
|
||||||
|
elog "Some systems may experience issues with copy and paste operations."
|
||||||
|
elog "If you encounter this, please install x11-misc/xsel."
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_postrm() {
|
||||||
|
gnome2_icon_cache_update
|
||||||
|
fdo-mime_mime_database_update
|
||||||
|
fdo-mime_desktop_database_update
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue