From 82bd3b0cbfb0af1555ed5b6b6f4edf2b6b17a144 Mon Sep 17 00:00:00 2001 From: Michael Raskin <7c6f434c@mail.ru> Date: Sat, 21 Dec 2019 01:22:15 +0100 Subject: rust-9p: init (cherry-picked from https://github.com/NixOS/nixpkgs/pull/76117) --- pkgs/servers/rust-9p/default.nix | 34 ++++++++++++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ 2 files changed, 36 insertions(+) create mode 100644 pkgs/servers/rust-9p/default.nix diff --git a/pkgs/servers/rust-9p/default.nix b/pkgs/servers/rust-9p/default.nix new file mode 100644 index 00000000000..115f1735d90 --- /dev/null +++ b/pkgs/servers/rust-9p/default.nix @@ -0,0 +1,34 @@ +{ stdenv, fetchFromGitHub, rustPlatform }: + +rustPlatform.buildRustPackage rec { + pname = "rust-9p"; + version = "0.0.2019-05-17"; + + src = fetchFromGitHub { + owner = "pfpacket"; + repo = pname; + rev = "01cf9c60bff0f35567d876db7be7fb86032b44eb"; + sha256 = "0mhmr1912z5nyfpcvhnlgb3v67a5n7i2n9l5abi05sfqffqssi79"; + }; + + sourceRoot = "source/example/unpfs"; + + cargoSha256 = "1d33nwj3i333a6ji3r3037mgg553lc3wsawm0pz13kbvhjf336i8"; + + RUSTC_BOOTSTRAP = 1; + + postInstall = '' + install -D -m 0444 ../../README* -t "$out/share/doc/${pname}" + install -D -m 0444 ../../LICEN* -t "$out/share/doc/${pname}" + ''; + + meta = with stdenv.lib; { + description = "9P2000.L server implementation in Rust"; + homepage = "https://github.com/pfpacket/rust-9p"; + license = licenses.bsd3; + maintainers = with maintainers; [ raskin ]; + + # macOS build fails: https://github.com/pfpacket/rust-9p/issues/7 + platforms = with platforms; linux; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 6b3c20fd99f..076bc5c83eb 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -15461,6 +15461,8 @@ in riemann = callPackage ../servers/monitoring/riemann { }; riemann-dash = callPackage ../servers/monitoring/riemann-dash { }; + rust-9p = callPackage ../servers/rust-9p {}; + oidentd = callPackage ../servers/identd/oidentd { }; openfire = callPackage ../servers/xmpp/openfire { }; -- cgit 1.4.1