Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ 2 lib, 3 stdenv, 4 fetchFromGitHub, 5}: 6 7stdenv.mkDerivation rec { 8 pname = "darkhttpd"; 9 version = "1.17"; 10 11 src = fetchFromGitHub { 12 owner = "emikulic"; 13 repo = "darkhttpd"; 14 rev = "v${version}"; 15 sha256 = "sha256-d5pDUY1EbVjykb4in4hhbgbjIXJtj133nRAQ84ASicQ="; 16 }; 17 18 enableParallelBuilding = true; 19 20 installPhase = '' 21 runHook preInstall 22 install -Dm555 -t $out/bin darkhttpd 23 install -Dm444 -t $out/share/doc/darkhttpd README.md 24 head -n 18 darkhttpd.c > $out/share/doc/darkhttpd/LICENSE 25 runHook postInstall 26 ''; 27 28 meta = with lib; { 29 description = "Small and secure static webserver"; 30 mainProgram = "darkhttpd"; 31 homepage = "https://unix4lyfe.org/darkhttpd/"; 32 license = licenses.bsd3; 33 maintainers = with maintainers; [ bobvanderlinden ]; 34 platforms = platforms.all; 35 }; 36}