1 { lib, stdenv, fetchFromGitHub, openssl, trousers, autoreconfHook, libtool, bison, flex }:
3 stdenv.mkDerivation rec {
4 pname = "opencryptoki";
7 src = fetchFromGitHub {
8 owner = "opencryptoki";
11 sha256 = "1rf7cmibmx636vzv7p54g212478a8wim2lfjf2861hfd0m96nv4l";
14 nativeBuildInputs = [ autoreconfHook libtool bison flex ];
15 buildInputs = [ openssl trousers ];
18 substituteInPlace configure.ac \
19 --replace "usermod" "true" \
20 --replace "groupadd" "true" \
21 --replace "chmod" "true" \
22 --replace "chgrp" "true"
23 substituteInPlace usr/lib/Makefile.am --replace "DESTDIR" "out"
32 enableParallelBuilding = true;
35 description = "PKCS#11 implementation for Linux";
36 homepage = "https://github.com/opencryptoki/opencryptoki";
37 license = licenses.cpl10;
39 platforms = platforms.unix;