git.iko.soy/typeable/nixpkgs
on master help sign in
mpw: 2.1 -> 2.6
commit3f3ac8829f04100bb9d1da2719fb8427474b5cb5 authorKilian Schweppe <ks@rx10.de> dateTue 7 Nov 2017, 19:12 (9 years ago) parent7e571b9
1 file changed+17−28
pkgs/tools/security/mpw/default.nix+17−28
pkgs/tools/security/mpw/default.nix+17−28
@@ -1,50 +1,39 @@
1−{ stdenv, fetchzip, autoconf, automake, openssl, libxml2, fetchFromGitHub, ncurses }:
1+{ stdenv, cmake, fetchFromGitHub, ncurses, libsodium, json_c }:
22
3−let
4− scrypt_src = fetchzip {
5− url = "http://www.tarsnap.com/scrypt/scrypt-1.2.0.tgz";
6− sha256 = "0ahylib2pimlhjcm566kpim6n16jci5v749xwdkr9ivgfjrv3xn4";
7− };
8−
9−in stdenv.mkDerivation {
10− name = "mpw-2.1-6834f36";
3+stdenv.mkDerivation rec {
4+ name = "mpw-2.6-f8043ae";
115
126 src = fetchFromGitHub {
137 owner = "Lyndir";
148 repo = "MasterPassword";
15− rev = "6834f3689f5dfd4e59ad6959961d349c224977ee";
16− sha256 = "0zlpx3hb1y2l60hg961h05lb9yf3xb5phnyycvazah2674gkwb2p";
9+ rev = "f8043ae16d73ddfb205aadd25c35cd9c5e95b228";
10+ sha256 = "0hy02ri7y3sca85z3ff5i68crwav5cjd7rrdqj7jrnpp1bw4yapi";
1711 };
1812
1913 postUnpack = ''
20− sourceRoot+=/MasterPassword/C
14+ sourceRoot+=/platform-independent/cli-c
2115 '';
2216
23− prePatch = ''
24− patchShebangs .
25− mkdir lib/scrypt/src
26− cp -R --no-preserve=ownership ${scrypt_src}/* lib/scrypt/src
27− chmod +w -R lib/scrypt/src
28− substituteInPlace lib/scrypt/src/libcperciva/cpusupport/Build/cpusupport.sh \
29− --replace dirname "$(type -P dirname)"
30− substituteInPlace lib/scrypt/src/Makefile.in --replace "command -p mv" "mv"
17+ preConfigure = ''
18+ substituteInPlace CMakeLists.txt --replace curses ncurses
19+ echo ${name} > VERSION
3120 '';
3221
33− NIX_CFLAGS_COMPILE = "-I${libxml2.dev}/include/libxml2";
22+ dontUseCmakeBuildDir = true;
3423
35− buildInputs = [ autoconf automake openssl libxml2 ncurses ];
24+ nativeBuildInputs = [ cmake ];
3625
37− buildPhase = ''
38− substituteInPlace build --replace '"curses"' '"ncurses"'
39− targets="mpw mpw-tests" ./build
40− '';
26+ buildInputs = [ ncurses libsodium json_c ];
4127
4228 installPhase = ''
4329 mkdir -p $out/bin
4430 mv mpw $out/bin/mpw
4531 '';
4632
47− meta = {
48− platforms = stdenv.lib.platforms.unix;
33+ meta = with stdenv.lib; {
34+ homepage = http://masterpasswordapp.com/;
35+ description = "A stateless password management solution";
36+ license = licenses.gpl3;
37+ platforms = platforms.unix;
4938 };
5039}