aboutsummaryrefslogtreecommitdiff
path: root/pkgs/crypto-wrapper
diff options
context:
space:
mode:
authorKarel Kočí <cynerd@email.cz>2022-10-03 22:21:02 +0200
committerKarel Kočí <cynerd@email.cz>2022-10-03 22:21:02 +0200
commitee4cfdda0a54567735e4c30662afd3f76e1c8a61 (patch)
treeb7ee78c18115932cef8f056ee86976c69067dc91 /pkgs/crypto-wrapper
parent018ea866e847e249b5ae59f8711f4b8e59c8f4ac (diff)
downloadnixturris-ee4cfdda0a54567735e4c30662afd3f76e1c8a61.tar.gz
nixturris-ee4cfdda0a54567735e4c30662afd3f76e1c8a61.tar.bz2
nixturris-ee4cfdda0a54567735e4c30662afd3f76e1c8a61.zip
crypto-wrapper: add and hopefully integrate the tools
Diffstat (limited to 'pkgs/crypto-wrapper')
-rw-r--r--pkgs/crypto-wrapper/default.nix18
1 files changed, 13 insertions, 5 deletions
diff --git a/pkgs/crypto-wrapper/default.nix b/pkgs/crypto-wrapper/default.nix
index 3f431b2..1d4d20b 100644
--- a/pkgs/crypto-wrapper/default.nix
+++ b/pkgs/crypto-wrapper/default.nix
@@ -1,9 +1,15 @@
{ stdenv, lib, fetchgit
-, bash
+, bash, openssl
, makeWrapper
+, libatsha204, mox-otp
}:
+let
-stdenv.mkDerivation rec {
+ bins = [openssl]
+ ++ lib.optional (stdenv.system == "aarch64-linux") mox-otp
+ ++ lib.optional (stdenv.system == "armv7l-linux") libatsha204;
+
+in stdenv.mkDerivation rec {
pname = "crypto-wrapper";
version = "0.4";
meta = with lib; {
@@ -19,10 +25,12 @@ stdenv.mkDerivation rec {
sha256 = "1ly37cajkmgqmlj230h5az9m2m1rgvf4r0bf94yipp80wl0z215s";
};
+ nativeBuildInputs = [ makeWrapper ];
+
+
installPhase = ''
mkdir -p $out/bin
- cp crypto-wrapper.sh $out/bin/crypto-wrapper
- wrapProgram $out/bin/crypto-wrapper \
- --prefix PATH : ${lib.makeBinPath [ bash openssl coreutils ]}
+ makeWrapper crypto-wrapper.sh $out/bin/crypto-wrapper \
+ --prefix PATH : ${lib.makeBinPath bins}
'';
}