Files
nixpkgs/pkgs/by-name/li/libmcrypt/package.nix
Dark Steveneq 646b892680
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
push sheeet
2025-10-09 14:15:47 +02:00

41 lines
1.1 KiB
Nix

{
lib,
stdenv,
fetchurl,
cctools,
disablePosixThreads ? false,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "libmcrypt";
version = "2.5.8";
src = fetchurl {
url = "mirror://sourceforge/mcrypt/Libmcrypt/${finalAttrs.version}/libmcrypt-${finalAttrs.version}.tar.gz";
hash = "sha256-5OtsB0u6sWisR7lHwZX/jO+dUaIRzdGMqcnvNNJ6Nz4=";
};
buildInputs = lib.optional stdenv.hostPlatform.isDarwin cctools;
configureFlags =
lib.optionals disablePosixThreads [ "--disable-posix-threads" ]
++ lib.optionals (stdenv.hostPlatform != stdenv.buildPlatform) [
# AC_FUNC_MALLOC is broken on cross builds.
"ac_cv_func_malloc_0_nonnull=yes"
"ac_cv_func_realloc_0_nonnull=yes"
];
env.NIX_CFLAGS_COMPILE = toString [
"-Wno-implicit-function-declaration"
"-Wno-implicit-int"
];
meta = {
description = "Replacement for the old crypt() package and crypt(1) command, with extensions";
mainProgram = "libmcrypt-config";
homepage = "https://mcrypt.sourceforge.net";
license = lib.licenses.lgpl21Plus;
platforms = lib.platforms.all;
};
})