summary refs log tree commit diff
path: root/pkgs/os-specific/linux/tomb
diff options
context:
space:
mode:
authorEthan Pailes <ethanpailes@gmail.com>2016-04-22 11:42:40 -0400
committerEthan Pailes <ethanpailes@gmail.com>2016-04-22 17:07:26 -0400
commit6a0903597ad05d73c902895677e05a66f011bff5 (patch)
tree07d065ff203ea445a457136f206320d4dc8e02ff /pkgs/os-specific/linux/tomb
parenta63aa838753dc8650e335ab555949df9b2603da1 (diff)
downloadnixlib-6a0903597ad05d73c902895677e05a66f011bff5.tar
nixlib-6a0903597ad05d73c902895677e05a66f011bff5.tar.gz
nixlib-6a0903597ad05d73c902895677e05a66f011bff5.tar.bz2
nixlib-6a0903597ad05d73c902895677e05a66f011bff5.tar.lz
nixlib-6a0903597ad05d73c902895677e05a66f011bff5.tar.xz
nixlib-6a0903597ad05d73c902895677e05a66f011bff5.tar.zst
nixlib-6a0903597ad05d73c902895677e05a66f011bff5.zip
tomb: init at version 2.2
Diffstat (limited to 'pkgs/os-specific/linux/tomb')
-rw-r--r--pkgs/os-specific/linux/tomb/default.nix41
1 files changed, 41 insertions, 0 deletions
diff --git a/pkgs/os-specific/linux/tomb/default.nix b/pkgs/os-specific/linux/tomb/default.nix
new file mode 100644
index 000000000000..5ed7ad5b959c
--- /dev/null
+++ b/pkgs/os-specific/linux/tomb/default.nix
@@ -0,0 +1,41 @@
+{ stdenv, fetchurl, zsh, pinentry, cryptsetup, gnupg1orig, makeWrapper }:
+
+let
+    version = "2.2";
+in
+
+stdenv.mkDerivation rec {
+  name = "tomb-${version}";
+
+  src = fetchurl {
+    url = "https://files.dyne.org/tomb/tomb-${version}.tar.gz";
+    sha256 = "11msj38fdmymiqcmwq1883kjqi5zr01ybdjj58rfjjrw4zw2w5y0";
+  };
+
+  buildInputs = [ makeWrapper ];
+
+  buildPhase = ''
+    # manually patch the interpreter
+    sed -i -e "1s|.*|#!${zsh}/bin/zsh|g" tomb
+  '';
+
+  installPhase = ''
+    mkdir -p $out/bin
+    mkdir -p $out/share/man/man1
+
+    cp tomb $out/bin/tomb
+    cp doc/tomb.1 $out/share/man/man1
+
+    wrapProgram $out/bin/tomb \
+        --prefix PATH : "${pinentry}/bin" \
+        --prefix PATH : "${cryptsetup}/bin" \
+        --prefix PATH : "${gnupg1orig}/bin"
+  '';
+
+  meta = {
+    description = "File encryption on GNU/Linux";
+    homepage = https://www.dyne.org/software/tomb/;
+    license = stdenv.lib.licenses.gpl3;
+    platforms = stdenv.lib.platforms.linux;
+  };
+}