2023-01-11 07:51:40 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, fetchFromGitHub
|
|
|
|
, autoreconfHook
|
|
|
|
, libtool
|
|
|
|
, pkg-config
|
2023-02-16 17:41:37 +00:00
|
|
|
, testers
|
2023-01-11 07:51:40 +00:00
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2023-02-16 17:41:37 +00:00
|
|
|
stdenv.mkDerivation (finalAttrs: {
|
2020-04-24 23:36:52 +00:00
|
|
|
pname = "libb2";
|
|
|
|
version = "0.98.1";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "BLAKE2";
|
|
|
|
repo = "libb2";
|
2023-02-16 17:41:37 +00:00
|
|
|
rev = "refs/tags/v${finalAttrs.version}";
|
2020-04-24 23:36:52 +00:00
|
|
|
sha256 = "0qj8aaqvfcavj1vj5asm4pqm03ap7q8x4c2fy83cqggvky0frgya";
|
|
|
|
};
|
|
|
|
|
2023-01-11 07:51:40 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
autoreconfHook
|
|
|
|
libtool
|
|
|
|
pkg-config
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
configureFlags = lib.optional stdenv.hostPlatform.isx86 "--enable-fat=yes";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2023-01-11 07:51:40 +00:00
|
|
|
enableParallelBuilding = true;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
doCheck = true;
|
|
|
|
|
2023-02-16 17:41:37 +00:00
|
|
|
passthru.tests.pkg-config = testers.testMetaPkgConfig finalAttrs.finalPackage;
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
meta = with lib; {
|
2024-06-20 14:57:18 +00:00
|
|
|
description = "BLAKE2 family of cryptographic hash functions";
|
2020-04-24 23:36:52 +00:00
|
|
|
homepage = "https://blake2.net/";
|
2023-02-16 17:41:37 +00:00
|
|
|
pkgConfigModules = [ "libb2" ];
|
2020-04-24 23:36:52 +00:00
|
|
|
platforms = platforms.all;
|
|
|
|
maintainers = with maintainers; [ dfoxfranke dotlambda ];
|
|
|
|
license = licenses.cc0;
|
|
|
|
};
|
2023-02-16 17:41:37 +00:00
|
|
|
})
|