nixpkgs/pkgs/servers/http/darkhttpd/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

35 lines
791 B
Nix
Raw Normal View History

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