linuxPackages.cryptodev: 1.6 -> 1.8, disable pic hardening

This commit is contained in:
Franz Pletz 2016-08-13 16:24:38 +02:00
parent f5c9f99877
commit d836b811cb

View File

@ -1,26 +1,19 @@
{ fetchurl, stdenv, kernel, onlyHeaders ? false }:
stdenv.mkDerivation rec {
pname = "cryptodev-linux-1.6";
pname = "cryptodev-linux-1.8";
name = "${pname}-${kernel.version}";
src = fetchurl {
url = "http://download.gna.org/cryptodev-linux/${pname}.tar.gz";
sha256 = "0bryzdb4xz3fp2q00a0mlqkj629md825lnlh4gjwmy51irf45wbm";
sha256 = "0xhkhcdlds9aiz0hams93dv0zkgcn2abaiagdjlqdck7zglvvyk7";
};
buildPhase = if !onlyHeaders then ''
make -C ${kernel.dev}/lib/modules/${kernel.modDirVersion}/build \
SUBDIRS=`pwd` INSTALL_PATH=$out
'' else ":";
hardeningDisable = [ "pic" ];
installPhase = stdenv.lib.optionalString (!onlyHeaders) ''
make -C ${kernel.dev}/lib/modules/${kernel.modDirVersion}/build \
INSTALL_MOD_PATH=$out SUBDIRS=`pwd` modules_install
'' + ''
mkdir -p $out/include/crypto
cp crypto/cryptodev.h $out/include/crypto
'';
KERNEL_DIR = "${kernel.dev}/lib/modules/${kernel.modDirVersion}/build";
INSTALL_MOD_PATH = "\${out}";
PREFIX = "\${out}";
meta = {
description = "Device that allows access to Linux kernel cryptographic drivers";