default.nix (856B)
1 { lib, stdenv, fetchFromGitHub, cmake, cxxtest, python3 }: 2 3 stdenv.mkDerivation rec { 4 pname = "subprocess"; 5 version = "0.4.0"; 6 7 src = fetchFromGitHub { 8 owner = "benman64"; 9 repo = "subprocess"; 10 rev = "v${version}"; 11 hash = "sha256-Tgmihv7SJfYpOYHvtuE8rgFzUHyl4bJh9W5CSqotVMg="; 12 }; 13 14 nativeBuildInputs = [ cmake cxxtest ]; 15 16 buildInputs = [ python3 ]; 17 18 installPhase = '' 19 install -Dm644 $src/src/cpp/*.hpp -t $out/include 20 install -Dm644 $src/src/cpp/subprocess/*.hpp -t $out/include/subprocess 21 install -Dm644 subprocess/libsubprocess.a -t $out/lib 22 ''; 23 24 meta = with lib; { 25 description = "Cross platform subprocess library for c++ similar to design of python subprocess"; 26 inherit (src.meta) homepage; 27 license = licenses.mit; 28 maintainers = [ maintainers.sikmir ]; 29 platforms = platforms.unix; 30 }; 31 }