1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-12-17 02:14:36 +00:00
nixpkgs/pkgs/tools/networking/tgt/default.nix
R. RyanTM e50674b6b2 tgt: 1.0.78 -> 1.0.79
Semi-automatic update generated by
https://github.com/ryantm/nixpkgs-update tools. This update was made
based on information from
https://repology.org/metapackage/tgt/versions
2019-07-17 09:34:00 +02:00

45 lines
1.1 KiB
Nix

{ stdenv, fetchFromGitHub, libxslt, libaio, systemd, perl, perlPackages
, docbook_xsl }:
stdenv.mkDerivation rec {
pname = "tgt";
version = "1.0.79";
src = fetchFromGitHub {
owner = "fujita";
repo = pname;
rev = "v${version}";
sha256 = "18bp7fcpv7879q3ppdxlqj7ayqmlh5zwrkz8gch6rq9lkmmrklrf";
};
buildInputs = [ libxslt systemd libaio docbook_xsl ];
makeFlags = [
"PREFIX=${placeholder "out"}"
"SD_NOTIFY=1"
];
installFlags = [
"sysconfdir=${placeholder "out"}/etc"
];
preConfigure = ''
sed -i 's|/usr/bin/||' doc/Makefile
sed -i 's|/usr/include/libaio.h|${libaio}/include/libaio.h|' usr/Makefile
sed -i 's|/usr/include/sys/|${stdenv.glibc.dev}/include/sys/|' usr/Makefile
sed -i 's|/usr/include/linux/|${stdenv.glibc.dev}/include/linux/|' usr/Makefile
'';
postInstall = ''
sed -i 's|#!/usr/bin/perl|#! ${perl}/bin/perl -I${perlPackages.ConfigGeneral}/${perl.libPrefix}|' $out/sbin/tgt-admin
'';
enableParallelBuilding = true;
meta = {
description = "iSCSI Target daemon with rdma support";
license = stdenv.lib.licenses.gpl2;
platforms = stdenv.lib.platforms.linux;
};
}