From 1d8bdf5389d49ba7216dd20bb7245ebb5208329d Mon Sep 17 00:00:00 2001 From: Matt Christ Date: Sat, 11 Sep 2021 18:18:31 -0500 Subject: [PATCH] stuntman: init at 1.2.16 --- pkgs/tools/networking/stuntman/default.nix | 45 ++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 + 2 files changed, 47 insertions(+) create mode 100644 pkgs/tools/networking/stuntman/default.nix diff --git a/pkgs/tools/networking/stuntman/default.nix b/pkgs/tools/networking/stuntman/default.nix new file mode 100644 index 00000000000..1825a3971a7 --- /dev/null +++ b/pkgs/tools/networking/stuntman/default.nix @@ -0,0 +1,45 @@ +{ stdenv, lib, fetchFromGitHub, openssl, boost }: + +stdenv.mkDerivation { + pname = "stuntman"; + version = "1.2.16"; + + src = fetchFromGitHub { + owner = "jselbie"; + repo = "stunserver"; + rev = "cfadf9c3836d5ae63a682913de24ba085df924f3"; + sha256 = "1gcx4zj44f0viddnn5klkmq0dgd29av5p06iyf9f1va4a3lk0cbg"; + }; + + buildInputs = [ + boost + openssl + ]; + + installPhase = '' + runHook preInstall + + mkdir -p $out/bin + mv stunserver $out/bin/ + mv stunclient $out/bin/ + + runHook postInstall + ''; + + doCheck = true; + checkPhase = '' + runHook preCheck + + ./stuntestcode + + runHook postCheck + ''; + + meta = with lib; { + description = "STUNTMAN - an open source STUN server and client"; + homepage = "http://www.stunprotocol.org/"; + license = licenses.asl20; + maintainers = with maintainers; [ mattchrist ]; + platforms = platforms.unix; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index d85a24a2a93..fc1e1ddb71c 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -9315,6 +9315,8 @@ with pkgs; stunnel = callPackage ../tools/networking/stunnel { }; + stuntman = callPackage ../tools/networking/stuntman { }; + stutter = haskell.lib.justStaticExecutables haskellPackages.stutter; strongswan = callPackage ../tools/networking/strongswan { };