Files
haikuports/app-admin/keepassxc/keepassxc-2.2.4.recipe
2017-12-18 16:57:19 +03:00

129 lines
4.0 KiB
Bash

SUMMARY="Qt password manager"
DESCRIPTION="KeePassXC 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.
KeePassXC 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.
KeePassXC 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.
KeePassXC is a community fork of KeePassX which aims to incorporate stalled \
pull requests, features, and bug fixes that have never made it into the main \
KeePassX repository."
HOMEPAGE="https://keepassxc.org/"
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
2013, Laszlo Papp
2013, David Faure
2016-2017, KeePassXC Team
"
LICENSE="GNU GPL v2"
REVISION="1"
SOURCE_URI="https://github.com/keepassxreboot/keepassxc/archive/$portVersion.tar.gz"
CHECKSUM_SHA256="e884439ed3ad461e426a25f0492f5fa78ab8ba06fb718977b3867d8f098ccd0a"
PATCHES="keepassxc-$portVersion.patchset"
ADDITIONAL_FILES="keepassxc.rdef.in"
ARCHITECTURES="!x86_gcc2 x86_64"
SECONDARY_ARCHITECTURES="x86"
PROVIDES="
keepassxc$secondaryArchSuffix = $portVersion
cmd:keepassxc_cli
"
REQUIRES="
haiku$secondaryArchSuffix
lib:libgcrypt$secondaryArchSuffix
lib:libgpg_error$secondaryArchSuffix
lib:libmicrohttpd$secondaryArchSuffix
lib:libQt5Concurrent$secondaryArchSuffix
lib:libQt5Core$secondaryArchSuffix
lib:libQt5DBus$secondaryArchSuffix
lib:libQt5Gui$secondaryArchSuffix
lib:libQt5Network$secondaryArchSuffix
lib:libQt5Test$secondaryArchSuffix
lib:libQt5Widgets$secondaryArchSuffix
lib:libz$secondaryArchSuffix
"
BUILD_REQUIRES="
haiku${secondaryArchSuffix}_devel
devel:libgcrypt$secondaryArchSuffix
devel:libgpg_error$secondaryArchSuffix
devel:libmicrohttpd$secondaryArchSuffix
devel:libQt5Concurrent$secondaryArchSuffix
devel:libQt5Core$secondaryArchSuffix
devel:libQt5DBus$secondaryArchSuffix
devel:libQt5Gui$secondaryArchSuffix
devel:libQt5Network$secondaryArchSuffix
devel:libQt5Test$secondaryArchSuffix
devel:libQt5Widgets$secondaryArchSuffix
devel:libz$secondaryArchSuffix
"
BUILD_PREREQUIRES="
cmd:cmake
cmd:g++$secondaryArchSuffix
cmd:make
cmd:qmake$secondaryArchSuffix >= 5
"
BUILD()
{
cmake -DCMAKE_INSTALL_PREFIX=$prefix \
-DCMAKE_INSTALL_DATAROOTDIR=$dataDir \
-DCMAKE_BUILD_TYPE=Release \
-DWITH_TESTS=on -DWITH_XC_AUTOTYPE=on .
make $jobArgs
}
INSTALL()
{
# TODO: adjust path for /boot/home/.config/keepassxc/keepassxc.ini
# TODO: replace icon with the one from keepassxc.svgz
# TODO: replace toolbar icons with https://github.com/HaikuArchives/ZumisIcons/tree/master/myhaiku/btoolbar
make install
appIconsDir=$dataDir/keepassxc/icons/application
rm -rf $appIconsDir/scalable
rm -rf $appIconsDir/16x16/apps
rm -rf $appIconsDir/*/mimetypes
for i in 24 32 48 64 128 256; do
rm -rf $appIconsDir/${i}x${i}
done
mkdir -p $appsDir
mv $prefix/bin/keepassxc $appsDir/KeePassXC
local APP_SIGNATURE="application/x-vnd.qt5-keepassxc"
local MAJOR="`echo "$portVersion" | cut -d. -f1`"
local MIDDLE="`echo "$portVersion" | cut -d. -f2`"
local MINOR="`echo "$portVersion" | cut -d. -f3`"
local LONG_INFO="$SUMMARY"
sed \
-e "s|@APP_SIGNATURE@|$APP_SIGNATURE|" \
-e "s|@MAJOR@|$MAJOR|" \
-e "s|@MIDDLE@|$MIDDLE|" \
-e "s|@MINOR@|$MINOR|" \
-e "s|@LONG_INFO@|$LONG_INFO|" \
$portDir/additional-files/keepassxc.rdef.in > keepassxc.rdef
addResourcesToBinaries keepassxc.rdef $appsDir/KeePassXC
addAppDeskbarSymlink $appsDir/KeePassXC
}
TEST()
{
make test
}