diff options
author | Jude Taylor <me@jude.bio> | 2015-09-29 17:56:32 -0700 |
---|---|---|
committer | Jude Taylor <me@jude.bio> | 2015-09-30 00:35:09 -0700 |
commit | de05a7b2ef1bb634d5e4e11c31ee9adc9a38197b (patch) | |
tree | d253a214f29a9aee25c8b53d2d5855bc174ee49d /pkgs/tools/security/mpw | |
parent | 5c7ba8c971605423d46045c364b42864a04909e2 (diff) |
add mpw
Diffstat (limited to 'pkgs/tools/security/mpw')
-rw-r--r-- | pkgs/tools/security/mpw/default.nix | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/pkgs/tools/security/mpw/default.nix b/pkgs/tools/security/mpw/default.nix new file mode 100644 index 0000000000000..15937a6792e69 --- /dev/null +++ b/pkgs/tools/security/mpw/default.nix @@ -0,0 +1,42 @@ +{ stdenv, fetchurl, autoconf, automake, openssl, libxml2 }: + +let + scrypt_src = fetchurl { + url = "http://masterpasswordapp.com/libscrypt-b12b554.tar.gz"; + sha256 = "02vz4i66v1acd15xjgki4ilmmp28m6a5603gi4hf8id3d3ndl9n7"; + }; + +in stdenv.mkDerivation { + name = "mpw-2.1-cli4"; + + srcs = [ + (fetchurl { + url = "https://ssl.masterpasswordapp.com/mpw-2.1-cli4-0-gf6b2287.tar.gz"; + sha256 = "141bzb3nj18rbnbpdvsri8cdwwwxz4d6akyhfa834542xf96b9vf"; + }) + scrypt_src + ]; + + sourceRoot = "."; + + postUnpack = '' + cp -R libscrypt-b12b554/* lib/scrypt + ''; + + prePatch = '' + patchShebangs . + ''; + + NIX_CFLAGS_COMPILE = "-I${libxml2}/include/libxml2"; + + buildInputs = [ autoconf automake openssl libxml2 ]; + + buildPhase = '' + targets="mpw mpw-tests" ./build + ''; + + installPhase = '' + mkdir -p $out/bin + mv mpw $out/bin/mpw + ''; +} |