mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-27 08:04:14 +00:00
571c71e6f7
We are migrating packages that meet below requirements: 1. using `callPackage` 2. called path is a directory 3. overriding set is empty (`{ }`) 4. not containing path expressions other than relative path (to makenixpkgs-vet happy) 5. not referenced by nix files outside of the directory, other than`pkgs/top-level/all-packages.nix` 6. not referencing nix files outside of the directory 7. not referencing `default.nix` (since it's changed to `package.nix`) 8. `outPath` doesn't change after migration The tool is here: https://github.com/Aleksanaa/by-name-migrate.
54 lines
1.4 KiB
Nix
54 lines
1.4 KiB
Nix
{ lib
|
|
, stdenv
|
|
, fetchFromGitHub
|
|
, autoreconfHook
|
|
, buildPackages
|
|
# libkcapi offers multiple tools. They can be disabled for minimization.
|
|
, kcapi-test ? true
|
|
, kcapi-speed ? true
|
|
, kcapi-hasher ? true
|
|
, kcapi-rngapp ? true
|
|
, kcapi-encapp ? true
|
|
, kcapi-dgstapp ? true
|
|
}:
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "libkcapi";
|
|
version = "1.5.0";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "smuellerDD";
|
|
repo = "libkcapi";
|
|
rev = "v${version}";
|
|
hash = "sha256-xOI29cjhUGUeHLaYIrPA5ZwwCE9lBdZG6kaW0lo1uL8=";
|
|
};
|
|
|
|
nativeBuildInputs = [ autoreconfHook ];
|
|
|
|
# libkcapi looks also for a host c compiler when cross-compiling
|
|
# otherwise you obtain following error message:
|
|
# "error: no acceptable C compiler found in $PATH"
|
|
depsBuildBuild = [
|
|
buildPackages.stdenv.cc
|
|
];
|
|
|
|
enableParallelBuilding = true;
|
|
|
|
configureFlags =
|
|
lib.optional kcapi-test "--enable-kcapi-test" ++
|
|
lib.optional kcapi-speed "--enable-kcapi-speed" ++
|
|
lib.optional kcapi-hasher "--enable-kcapi-hasher" ++
|
|
lib.optional kcapi-rngapp "--enable-kcapi-rngapp" ++
|
|
lib.optional kcapi-encapp "--enable-kcapi-encapp" ++
|
|
lib.optional kcapi-dgstapp "--enable-kcapi-dgstapp"
|
|
;
|
|
|
|
meta = {
|
|
homepage = "http://www.chronox.de/libkcapi.html";
|
|
description = "Linux Kernel Crypto API User Space Interface Library";
|
|
license = with lib.licenses; [ bsd3 gpl2Only ];
|
|
platforms = lib.platforms.linux;
|
|
maintainers = with lib.maintainers; [ orichter thillux ];
|
|
};
|
|
}
|