2017-11-08 23:04:09 +01:00
|
|
|
{ stdenv, fetchurl, libtool }:
|
2014-10-15 03:05:51 +02:00
|
|
|
|
2017-11-08 23:04:09 +01:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "libtomcrypt-${version}";
|
2018-02-27 06:11:51 +01:00
|
|
|
version = "1.18.1";
|
2014-10-15 03:05:51 +02:00
|
|
|
|
|
|
|
src = fetchurl {
|
2017-11-08 23:04:09 +01:00
|
|
|
url = "https://github.com/libtom/libtomcrypt/releases/download/v${version}/crypt-${version}.tar.xz";
|
2018-02-27 06:11:51 +01:00
|
|
|
sha256 = "053z0jzyvf6c9929phlh2p0ybx289s34g7nii5hnjigxzcs3mhap";
|
2014-10-15 03:05:51 +02:00
|
|
|
};
|
|
|
|
|
2017-11-08 23:04:09 +01:00
|
|
|
nativeBuildInputs = [ libtool ];
|
|
|
|
|
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace makefile.shared --replace "LT:=glibtool" "LT:=libtool"
|
|
|
|
'';
|
2014-10-15 03:05:51 +02:00
|
|
|
|
|
|
|
preBuild = ''
|
2017-11-08 23:04:09 +01:00
|
|
|
makeFlagsArray=(PREFIX=$out \
|
2014-10-15 03:05:51 +02:00
|
|
|
INSTALL_GROUP=$(id -g) \
|
|
|
|
INSTALL_USER=$(id -u))
|
|
|
|
'';
|
|
|
|
|
|
|
|
makefile = "makefile.shared";
|
|
|
|
|
2017-11-08 23:04:09 +01:00
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
homepage = http://www.libtom.net/LibTomCrypt/;
|
2015-04-30 17:05:14 +02:00
|
|
|
description = "A fairly comprehensive, modular and portable cryptographic toolkit";
|
2017-11-08 23:04:09 +01:00
|
|
|
license = with licenses; [ publicDomain wtfpl ];
|
|
|
|
platforms = platforms.linux;
|
2014-10-15 03:05:51 +02:00
|
|
|
};
|
|
|
|
}
|