summary refs log tree commit diff
path: root/pkgs/tools/networking/shadowsocks-rust
diff options
context:
space:
mode:
authorMario Rodas <marsam@users.noreply.github.com>2019-03-01 19:59:49 -0500
committerMario Rodas <marsam@users.noreply.github.com>2019-03-16 07:35:08 -0500
commit3039cfcfde632263ac2cc8fcdcb1db4a5166146b (patch)
tree6d3bbc760fbdd6cfc4931c73adf5187fb27b1ad4 /pkgs/tools/networking/shadowsocks-rust
parent0610d30e5b9920787c0b53a271b0cd1fde66aeb2 (diff)
downloadnixpkgs-3039cfcfde632263ac2cc8fcdcb1db4a5166146b.tar
nixpkgs-3039cfcfde632263ac2cc8fcdcb1db4a5166146b.tar.gz
nixpkgs-3039cfcfde632263ac2cc8fcdcb1db4a5166146b.tar.bz2
nixpkgs-3039cfcfde632263ac2cc8fcdcb1db4a5166146b.tar.lz
nixpkgs-3039cfcfde632263ac2cc8fcdcb1db4a5166146b.tar.xz
nixpkgs-3039cfcfde632263ac2cc8fcdcb1db4a5166146b.tar.zst
nixpkgs-3039cfcfde632263ac2cc8fcdcb1db4a5166146b.zip
shadowsocks-rust: init at 1.7.0
Diffstat (limited to 'pkgs/tools/networking/shadowsocks-rust')
-rw-r--r--pkgs/tools/networking/shadowsocks-rust/default.nix29
1 files changed, 29 insertions, 0 deletions
diff --git a/pkgs/tools/networking/shadowsocks-rust/default.nix b/pkgs/tools/networking/shadowsocks-rust/default.nix
new file mode 100644
index 00000000000..6a024b72f73
--- /dev/null
+++ b/pkgs/tools/networking/shadowsocks-rust/default.nix
@@ -0,0 +1,29 @@
+{ stdenv, fetchFromGitHub, rustPlatform, pkgconfig, openssl, libsodium, Security }:
+
+rustPlatform.buildRustPackage rec {
+  pname = "shadowsocks-rust";
+  version = "1.7.0";
+
+  src = fetchFromGitHub {
+    rev = "v${version}";
+    owner = "shadowsocks";
+    repo = pname;
+    sha256 = "0mqjm54mp6c9mfdl3gf01v9vm2rjll8fw63n6j4qgv01y4hrsm4f";
+  };
+
+  cargoSha256 = "1m0p40z6qx6s0r1x6apz56n2s4ppn8b2cff476xrfhp6s1j046q7";
+
+  buildInputs = [ openssl libsodium ]
+    ++ stdenv.lib.optionals stdenv.isDarwin [ Security ];
+  nativeBuildInputs = [ pkgconfig ];
+
+  # tries to read /etc/resolv.conf, hence fails in sandbox
+  doCheck = false;
+
+  meta = with stdenv.lib; {
+    homepage = https://github.com/shadowsocks/shadowsocks-rust;
+    description = "A Rust port of shadowsocks";
+    license = licenses.mit;
+    maintainers = [ maintainers.marsam ];
+  };
+}