2018-10-12 19:04:09 +02:00
|
|
|
{ stdenv, fetchFromGitHub, cmake, pkgconfig, zip, gettext, perl
|
2019-04-25 21:23:44 +02:00
|
|
|
, wxGTK31, libXext, libXi, libXt, libXtst, xercesc
|
2019-01-01 17:19:07 +01:00
|
|
|
, qrencode, libuuid, libyubikey, yubikey-personalization
|
2019-04-25 21:23:44 +02:00
|
|
|
, curl, openssl
|
2015-01-22 23:46:40 +01:00
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2018-10-12 19:04:09 +02:00
|
|
|
pname = "pwsafe";
|
2019-09-28 00:43:46 +02:00
|
|
|
version = "1.08.2";
|
2015-01-22 23:46:40 +01:00
|
|
|
|
2016-07-23 06:37:10 +02:00
|
|
|
src = fetchFromGitHub {
|
2019-05-21 14:14:09 +02:00
|
|
|
owner = pname;
|
|
|
|
repo = pname;
|
2016-07-23 06:37:10 +02:00
|
|
|
rev = "${version}BETA";
|
2019-09-28 00:43:46 +02:00
|
|
|
sha256 = "14qwk3cv5psj7ll71ikyv452x55c7iwjw9765yrpij6741r4yjln";
|
2015-01-22 23:46:40 +01:00
|
|
|
};
|
|
|
|
|
2019-04-25 21:23:44 +02:00
|
|
|
nativeBuildInputs = [
|
2019-05-21 14:14:09 +02:00
|
|
|
cmake gettext perl pkgconfig zip
|
2019-04-25 21:23:44 +02:00
|
|
|
];
|
2018-10-12 19:04:09 +02:00
|
|
|
buildInputs = [
|
2019-04-25 21:23:44 +02:00
|
|
|
libXext libXi libXt libXtst wxGTK31
|
|
|
|
curl qrencode libuuid openssl xercesc
|
2018-10-12 19:04:09 +02:00
|
|
|
libyubikey yubikey-personalization
|
|
|
|
];
|
2019-04-25 21:23:44 +02:00
|
|
|
|
2018-10-12 19:04:09 +02:00
|
|
|
cmakeFlags = [
|
|
|
|
"-DNO_GTEST=ON"
|
|
|
|
"-DCMAKE_CXX_FLAGS=-I${yubikey-personalization}/include/ykpers-1"
|
|
|
|
];
|
|
|
|
enableParallelBuilding = true;
|
2015-01-22 23:46:40 +01:00
|
|
|
|
|
|
|
postPatch = ''
|
|
|
|
# Fix perl scripts used during the build.
|
|
|
|
for f in `find . -type f -name '*.pl'`; do
|
|
|
|
patchShebangs $f
|
|
|
|
done
|
|
|
|
|
|
|
|
# Fix hard coded paths.
|
|
|
|
for f in `grep -Rl /usr/share/ src`; do
|
|
|
|
substituteInPlace $f --replace /usr/share/ $out/share/
|
|
|
|
done
|
|
|
|
|
2016-07-23 06:37:10 +02:00
|
|
|
# Fix hard coded zip path.
|
|
|
|
substituteInPlace help/Makefile.linux --replace /usr/bin/zip ${zip}/bin/zip
|
|
|
|
|
2015-01-22 23:46:40 +01:00
|
|
|
for f in `grep -Rl /usr/bin/ .`; do
|
|
|
|
substituteInPlace $f --replace /usr/bin/ ""
|
|
|
|
done
|
|
|
|
'';
|
|
|
|
|
2019-05-21 14:14:09 +02:00
|
|
|
installFlags = [ "PREFIX=${placeholder "out"}" ];
|
2015-01-22 23:46:40 +01:00
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
2015-04-30 17:05:14 +02:00
|
|
|
description = "A password database utility";
|
2015-01-22 23:46:40 +01:00
|
|
|
longDescription = ''
|
|
|
|
Password Safe is a password database utility. Like many other
|
|
|
|
such products, commercial and otherwise, it stores your
|
|
|
|
passwords in an encrypted file, allowing you to remember only
|
|
|
|
one password (the "safe combination"), instead of all the
|
|
|
|
username/password combinations that you use.
|
|
|
|
'';
|
2019-05-21 14:14:09 +02:00
|
|
|
homepage = "https://pwsafe.org/";
|
2018-10-12 19:04:09 +02:00
|
|
|
maintainers = with maintainers; [ c0bw3b pjones ];
|
2015-01-22 23:46:40 +01:00
|
|
|
platforms = platforms.linux;
|
|
|
|
license = licenses.artistic2;
|
|
|
|
};
|
|
|
|
}
|