2018-10-16 16:49:52 +02:00
|
|
|
{ stdenv
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
2019-03-19 16:11:46 +01:00
|
|
|
, python
|
|
|
|
, c-ares
|
|
|
|
, cffi
|
2018-10-16 16:49:52 +02:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pycares";
|
2019-12-19 20:31:18 +01:00
|
|
|
version = "3.1.0";
|
2018-10-16 16:49:52 +02:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2019-12-19 20:31:18 +01:00
|
|
|
sha256 = "663c000625725d3a63466a674df4ee7f62bf8ca1ae8a0b87a6411eb811e0e794";
|
2018-10-16 16:49:52 +02:00
|
|
|
};
|
|
|
|
|
2019-03-19 16:11:46 +01:00
|
|
|
buildInputs = [ c-ares ];
|
2018-10-16 16:49:52 +02:00
|
|
|
|
2019-03-19 16:11:46 +01:00
|
|
|
propagatedBuildInputs = [ cffi ];
|
|
|
|
|
|
|
|
checkPhase = ''
|
|
|
|
${python.interpreter} tests/tests.py
|
|
|
|
'';
|
|
|
|
|
|
|
|
# requires network access
|
2018-10-16 16:49:52 +02:00
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
homepage = https://github.com/saghul/pycares;
|
|
|
|
description = "Interface for c-ares";
|
|
|
|
license = licenses.mit;
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|