2022-10-30 15:09:59 +00:00
|
|
|
{ lib, stdenv, fetchurl, perl, nixosTests }:
|
2021-03-09 03:18:52 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "libxcrypt";
|
2022-12-17 10:02:37 +00:00
|
|
|
version = "4.4.33";
|
2021-03-09 03:18:52 +00:00
|
|
|
|
2022-10-30 15:09:59 +00:00
|
|
|
src = fetchurl {
|
|
|
|
url = "https://github.com/besser82/libxcrypt/releases/download/v${version}/libxcrypt-${version}.tar.xz";
|
2022-12-17 10:02:37 +00:00
|
|
|
hash = "sha256-6HrPnGUsVzpHE9VYIVn5jzBdVu1fdUzmT1fUGU1rOm8=";
|
2021-03-09 03:18:52 +00:00
|
|
|
};
|
|
|
|
|
2022-10-30 15:09:59 +00:00
|
|
|
outputs = [
|
|
|
|
"out"
|
|
|
|
"man"
|
2022-10-06 18:32:54 +00:00
|
|
|
];
|
|
|
|
|
2022-04-27 09:35:20 +00:00
|
|
|
configureFlags = [
|
2022-10-30 15:09:59 +00:00
|
|
|
"--enable-hashes=all"
|
|
|
|
"--enable-obsolete-api=glibc"
|
|
|
|
"--disable-failure-tokens"
|
2022-11-27 09:42:12 +00:00
|
|
|
] ++ lib.optionals (stdenv.hostPlatform.isMusl || stdenv.hostPlatform.libc == "bionic") [
|
2022-04-27 09:35:20 +00:00
|
|
|
"--disable-werror"
|
|
|
|
];
|
|
|
|
|
2022-10-30 15:09:59 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
perl
|
|
|
|
];
|
|
|
|
|
|
|
|
enableParallelBuilding = true;
|
2021-03-09 03:18:52 +00:00
|
|
|
|
2022-11-21 17:40:18 +00:00
|
|
|
doCheck = true;
|
2022-10-30 15:09:59 +00:00
|
|
|
|
|
|
|
passthru.tests = {
|
|
|
|
inherit (nixosTests) login shadow;
|
|
|
|
};
|
2021-03-09 03:18:52 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Extended crypt library for descrypt, md5crypt, bcrypt, and others";
|
|
|
|
homepage = "https://github.com/besser82/libxcrypt/";
|
|
|
|
platforms = platforms.all;
|
2022-10-30 15:09:59 +00:00
|
|
|
maintainers = with maintainers; [ dottedmag hexa ];
|
2021-03-09 03:18:52 +00:00
|
|
|
license = licenses.lgpl21Plus;
|
|
|
|
};
|
|
|
|
}
|