2018-07-17 13:11:16 -07:00
|
|
|
{ stdenv, lib, fetchurl, makeWrapper, pkgconfig, udev, dbus, pcsclite
|
2018-12-14 19:50:31 -08:00
|
|
|
, wget, coreutils, perlPackages
|
2015-11-13 04:24:03 -08:00
|
|
|
}:
|
2015-03-09 03:50:44 -07:00
|
|
|
|
2016-04-13 05:53:51 -07:00
|
|
|
let deps = lib.makeBinPath [ wget coreutils ];
|
2015-11-13 04:24:03 -08:00
|
|
|
|
|
|
|
in stdenv.mkDerivation rec {
|
2020-07-09 20:51:17 -07:00
|
|
|
name = "pcsc-tools-1.5.7";
|
2015-03-09 03:50:44 -07:00
|
|
|
|
|
|
|
src = fetchurl {
|
2018-10-11 13:34:28 -07:00
|
|
|
url = "http://ludovic.rousseau.free.fr/softwares/pcsc-tools/${name}.tar.bz2";
|
2020-07-09 20:51:17 -07:00
|
|
|
sha256 = "17b9jxvcxmn007lavan20l25v4jvm6dqc4x9dlqzbg6mjs28zsp0";
|
2015-03-09 03:50:44 -07:00
|
|
|
};
|
|
|
|
|
2018-12-14 19:50:31 -08:00
|
|
|
buildInputs = [ udev dbus perlPackages.perl pcsclite ];
|
2015-03-09 03:50:44 -07:00
|
|
|
|
2015-11-13 04:24:03 -08:00
|
|
|
nativeBuildInputs = [ makeWrapper pkgconfig ];
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
wrapProgram $out/bin/scriptor \
|
2018-12-14 19:50:31 -08:00
|
|
|
--set PERL5LIB "${with perlPackages; makePerlPath [ pcscperl ]}"
|
2015-11-13 04:24:03 -08:00
|
|
|
wrapProgram $out/bin/gscriptor \
|
2020-07-10 05:08:14 -07:00
|
|
|
--set PERL5LIB "${with perlPackages; makePerlPath [ pcscperl GlibObjectIntrospection Glib Gtk3 Pango Cairo CairoGObject ]}"
|
2015-11-13 04:24:03 -08:00
|
|
|
wrapProgram $out/bin/ATR_analysis \
|
2018-12-14 19:50:31 -08:00
|
|
|
--set PERL5LIB "${with perlPackages; makePerlPath [ pcscperl ]}"
|
2015-11-13 04:24:03 -08:00
|
|
|
wrapProgram $out/bin/pcsc_scan \
|
|
|
|
--set PATH "$out/bin:${deps}"
|
|
|
|
'';
|
2015-03-09 03:50:44 -07:00
|
|
|
|
2015-11-13 04:24:03 -08:00
|
|
|
meta = with lib; {
|
2015-03-09 03:50:44 -07:00
|
|
|
description = "Tools used to test a PC/SC driver, card or reader";
|
2020-03-11 03:48:17 -07:00
|
|
|
homepage = "http://ludovic.rousseau.free.fr/softwares/pcsc-tools/";
|
2015-03-09 08:01:10 -07:00
|
|
|
license = licenses.gpl2Plus;
|
2018-07-22 12:50:19 -07:00
|
|
|
maintainers = with maintainers; [ ];
|
2015-11-17 12:29:29 -08:00
|
|
|
platforms = platforms.linux;
|
2015-03-09 03:50:44 -07:00
|
|
|
};
|
|
|
|
}
|