keepassx: update to 2.0a6

This commit is contained in:
Chris Roberts
2014-11-13 21:23:54 -07:00
parent 59e94b4ef7
commit be7278cbba
2 changed files with 175 additions and 0 deletions

View File

@@ -0,0 +1,90 @@
SUMMARY="Qt password manager"
DESCRIPTION="
KeePassX is an application for people with extremly high demands on secure \
personal data management. It has a light interface, is cross platform and \
published under the terms of the GNU General Public License.
KeePassX saves many different information e.g. user names, passwords, urls, \
attachments and comments in one single database. For a better management \
user-defined titles and icons can be specified for each single entry. \
Furthermore the entries are sorted in groups, which are customizable as well. \
The integrated search function allows to search in a single group or the \
complete database.
KeePassX offers a little utility for secure password generation. The password \
generator is very customizable, fast and easy to use. Especially someone who \
generates passwords frequently will appreciate this feature.
"
HOMEPAGE="http://www.keepassx.org/"
SRC_URI="https://github.com/keepassx/keepassx/archive/2.0-alpha6.zip"
CHECKSUM_SHA256="3e4c2f3c5dd278cd139f4e91351aa3f9b435c8da506f14031edda44566365dc3"
COPYRIGHT="
2010-2012, Felix Geyer
2011-2012, Florian Geyer
2012, Tobias Tangemann
2007, Trolltech ASA
2012, Intel Corporation
2012, Nokia Corporation and/or its subsidiary(-ies)
2000-2008, Tom Sato
"
LICENSE="GNU GPL v2"
REVISION="1"
ARCHITECTURES="x86"
PROVIDES="
keepassx = $portVersion
app:keepassx = $portVersion
"
REQUIRES="
haiku >= $haikuVersion
lib:libgcrypt
lib:libQtCore
lib:libQtGui
lib:libz
"
BUILD_REQUIRES="
haiku_devel >= $haikuVersion
devel:libz
devel:libgcrypt
devel:libgpg_error
devel:libQtCore
devel:libQtGui
"
BUILD_PREREQUIRES="
cmd:cmake
cmd:make
cmd:g++
cmd:qmake
cmd:moc
cmd:xres
"
PATCHES="keepassx-2.0a6.patchset"
SOURCE_DIR="keepassx-2.0-alpha6"
BUILD()
{
cmake -DCMAKE_INSTALL_PREFIX=$prefix \
-DCMAKE_INSTALL_DATAROOTDIR=$dataDir \
-DCMAKE_BUILD_TYPE=Release \
-DWITH_TESTS=off .
make $jobArgs
rc $portDir/additional-files/keepassx.rdef \
-o $sourceDir/src/keepassx.rsrc
xres -o $sourceDir/src/keepassx $sourceDir/src/keepassx.rsrc
mimeset -f $sourceDir/src/keepassx
}
INSTALL()
{
make install
mkdir -p $appsDir
mv $binDir/keepassx $appsDir/KeePassX
addAppDeskbarSymlink $appsDir/KeePassX KeePassX
}

View File

@@ -0,0 +1,85 @@
From 13f3d262fd9c6c0cf9f32f7ec8bef110b0aa71ca Mon Sep 17 00:00:00 2001
From: Chris Roberts <cpr420@gmail.com>
Date: Thu, 13 Nov 2014 19:28:44 -0700
Subject: Add Haiku support
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 35642eb..73763a0 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -159,7 +159,7 @@ if(WITH_TESTS)
endif(WITH_TESTS)
set(QT_REQUIRED_MODULES QtCore QtGui QtTest)
-if(UNIX AND NOT APPLE)
+if(UNIX AND NOT APPLE AND NOT HAIKU)
set(QT_REQUIRED_MODULES ${QT_REQUIRED_MODULES} QtDBus)
endif()
diff --git a/share/CMakeLists.txt b/share/CMakeLists.txt
index 7069c6c..cef431e 100644
--- a/share/CMakeLists.txt
+++ b/share/CMakeLists.txt
@@ -17,7 +17,7 @@ file(GLOB DATABASE_ICONS icons/database/*.png)
install(FILES ${DATABASE_ICONS} DESTINATION ${DATA_INSTALL_DIR}/icons/database)
-if(UNIX AND NOT APPLE)
+if(UNIX AND NOT APPLE AND NOT HAIKU)
install(DIRECTORY icons/application/ DESTINATION share/icons/hicolor
FILES_MATCHING PATTERN "keepassx.png" PATTERN "keepassx.svgz")
install(DIRECTORY icons/application/ DESTINATION share/icons/hicolor
diff --git a/src/config-keepassx.h.cmake b/src/config-keepassx.h.cmake
index 9a3f495..e4efe17 100644
--- a/src/config-keepassx.h.cmake
+++ b/src/config-keepassx.h.cmake
@@ -9,6 +9,8 @@
#define KEEPASSX_PLUGIN_DIR "${PLUGIN_INSTALL_DIR}"
+#define KEEPASSX_DATA_DIR "${DATA_INSTALL_DIR}"
+
#cmakedefine HAVE_PR_SET_DUMPABLE 1
#cmakedefine HAVE_RLIMIT_CORE 1
#cmakedefine HAVE_PT_DENY_ATTACH 1
diff --git a/src/core/FilePath.cpp b/src/core/FilePath.cpp
index 52db1ed..8688ea9 100644
--- a/src/core/FilePath.cpp
+++ b/src/core/FilePath.cpp
@@ -182,6 +182,10 @@ FilePath::FilePath()
else if (testSetDir(QCoreApplication::applicationDirPath() + "/share")) {
}
#endif
+#ifdef KEEPASSX_DATA_DIR
+ else if (testSetDir(QString(KEEPASSX_DATA_DIR))) {
+ }
+#endif
if (m_dataPath.isEmpty()) {
qWarning("FilePath::DataPath: can't find data dir");
diff --git a/src/gui/Clipboard.cpp b/src/gui/Clipboard.cpp
index eb77d2b..958eacb 100644
--- a/src/gui/Clipboard.cpp
+++ b/src/gui/Clipboard.cpp
@@ -21,7 +21,7 @@
#include <QClipboard>
#include <QTimer>
-#if defined(Q_OS_UNIX) && !defined(Q_OS_MAC)
+#if defined(Q_OS_UNIX) && !defined(Q_OS_MAC) && !defined(Q_OS_HAIKU)
#include <QDBusConnection>
#include <QDBusMessage>
#endif
@@ -70,7 +70,7 @@ void Clipboard::clearClipboard()
clipboard->clear(QClipboard::Selection);
}
-#if defined(Q_OS_UNIX) && !defined(Q_OS_MAC)
+#if defined(Q_OS_UNIX) && !defined(Q_OS_MAC) && !defined(Q_OS_HAIKU)
QDBusMessage message = QDBusMessage::createMethodCall("org.kde.klipper", "/klipper", "", "clearClipboardHistory");
QDBusConnection::sessionBus().send(message);
#endif
--
1.8.3.4