{ cargo, fetchFromGitHub, makeWrapper, pkgconfig, rustPlatform, stdenv, gcc, Security, cmake }: rustPlatform.buildRustPackage rec { pname = "evcxr"; version = "0.4.6"; src = fetchFromGitHub { owner = "google"; repo = "evcxr"; rev = "v${version}"; sha256 = "1yzvqf93zz3ncck4dyq2kayp408lm3h6fx0fb212j7h70mlzx984"; }; cargoSha256 = "0g17g12isah4nkqp9i299qr1sz19k4czcc43rm1wbs0y9szaqvwc"; nativeBuildInputs = [ pkgconfig makeWrapper cmake ]; buildInputs = stdenv.lib.optional stdenv.isDarwin Security; postInstall = '' wrapProgram $out/bin/evcxr --prefix PATH : ${stdenv.lib.makeBinPath [ cargo gcc ]} rm $out/bin/testing_runtime ''; meta = with stdenv.lib; { description = "An evaluation context for Rust"; homepage = "https://github.com/google/evcxr"; license = licenses.asl20; maintainers = with maintainers; [ protoben ma27 ]; platforms = platforms.all; }; }