3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/servers/http/darkhttpd/default.nix

35 lines
792 B
Nix
Raw Normal View History

2021-02-21 17:15:49 +00:00
{ lib
, stdenv
, fetchFromGitHub
}:
2015-11-19 13:46:59 +00:00
stdenv.mkDerivation rec {
pname = "darkhttpd";
2021-02-21 17:15:49 +00:00
version = "1.13";
2015-11-19 13:46:59 +00:00
2021-02-21 17:15:49 +00:00
src = fetchFromGitHub {
owner = "emikulic";
repo = pname;
rev = "v${version}";
sha256 = "0w11xq160q9yyffv4mw9ncp1n0dl50d9plmwxb0yijaaxls9i4sk";
2015-11-19 13:46:59 +00:00
};
2017-08-28 14:19:40 +01:00
enableParallelBuilding = true;
2015-11-19 13:46:59 +00:00
2017-08-28 14:19:40 +01:00
installPhase = ''
2021-02-21 17:15:49 +00:00
runHook preInstall
2021-01-14 02:51:14 +00:00
install -Dm555 -t $out/bin darkhttpd
2021-02-21 17:15:49 +00:00
install -Dm444 -t $out/share/doc/${pname} README.md
2021-01-14 02:51:14 +00:00
head -n 18 darkhttpd.c > $out/share/doc/${pname}/LICENSE
2021-02-21 17:15:49 +00:00
runHook postInstall
2015-11-19 13:46:59 +00:00
'';
meta = with lib; {
2015-11-19 13:46:59 +00:00
description = "Small and secure static webserver";
2021-01-14 02:51:14 +00:00
homepage = "https://unix4lyfe.org/darkhttpd/";
license = licenses.bsd3;
2017-08-28 14:19:40 +01:00
maintainers = with maintainers; [ bobvanderlinden ];
2021-01-14 02:51:14 +00:00
platforms = platforms.all;
2015-11-19 13:46:59 +00:00
};
}