Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at 20.09 874 B view raw
1{ stdenv, fetchFromGitHub, cmake, python }: 2 3stdenv.mkDerivation rec { 4 version = "0.6.3"; 5 pname = "docopt.cpp"; 6 7 src = fetchFromGitHub { 8 owner = "docopt"; 9 repo = "docopt.cpp"; 10 rev = "v${version}"; 11 sha256 = "0cz3vv7g5snfbsqcf3q8bmd6kv5qp84gj3avwkn4vl00krw13bl7"; 12 }; 13 14 nativeBuildInputs = [ cmake python ]; 15 16 cmakeFlags = ["-DWITH_TESTS=ON"]; 17 18 doCheck = true; 19 20 postPatch = '' 21 substituteInPlace docopt.pc.in \ 22 --replace "@CMAKE_INSTALL_PREFIX@/@CMAKE_INSTALL_LIBDIR@" \ 23 "@CMAKE_INSTALL_LIBDIR@" 24 ''; 25 26 checkPhase = "LD_LIBRARY_PATH=$(pwd) python ./run_tests"; 27 28 meta = with stdenv.lib; { 29 description = "C++11 port of docopt"; 30 homepage = "https://github.com/docopt/docopt.cpp"; 31 license = with licenses; [ mit boost ]; 32 platforms = platforms.all; 33 maintainers = with maintainers; [ knedlsepp ]; 34 }; 35}