Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib, stdenv, fetchurl, fetchpatch, autoreconfHook }:
2
3stdenv.mkDerivation rec {
4 pname = "libmd";
5 version = "1.0.4";
6
7 src = fetchurl {
8 urls = [
9 "https://archive.hadrons.org/software/libmd/libmd-${version}.tar.xz"
10 "https://libbsd.freedesktop.org/releases/libmd-${version}.tar.xz"
11 ];
12 sha256 = "sha256-9RySEELjS+3e3tS3VVdlZVnPWx8kSAM7TB7sEcB+Uw8=";
13 };
14
15 patches = [
16 # Drop aliases for SHA384 functions, because such aliases are not supported on Darwin.
17 (fetchpatch {
18 url = "https://github.com/macports/macports-ports/raw/8332f5dbcaf05a02bc31fbd4ccf735e7d5c9a5b0/devel/libmd/files/patch-symbol-alias.diff";
19 sha256 = "sha256-py5hMpKYKwtBzhWn01lFc2a6+OZN72YCYXyhg1qe6rg=";
20 extraPrefix = "";
21 })
22 ];
23
24 nativeBuildInputs = [ autoreconfHook ];
25
26 meta = with lib; {
27 homepage = "https://www.hadrons.org/software/${pname}/";
28 changelog = "https://archive.hadrons.org/software/libmd/libmd-${version}.announce";
29 # Git: https://git.hadrons.org/cgit/libmd.git
30 description = "Message Digest functions from BSD systems";
31 license = with licenses; [ bsd3 bsd2 isc beerware publicDomain ];
32 maintainers = with maintainers; [ primeos ];
33 platforms = platforms.unix;
34 };
35}