2020-09-07 20:47:30 +00:00
|
|
|
{ lib, buildPythonPackage, fetchPypi, openssl, async_generator, rsa, pyaes, pythonOlder }:
|
2019-01-29 13:45:21 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "telethon";
|
2020-11-29 08:13:58 +00:00
|
|
|
version = "1.17.5";
|
2019-01-29 13:45:21 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit version;
|
|
|
|
pname = "Telethon";
|
2020-11-29 08:13:58 +00:00
|
|
|
sha256 = "1v1rgr030z8s1ldv5lm1811znyd568c22pmlrzzf3ls972xk514m";
|
2019-01-29 13:45:21 +00:00
|
|
|
};
|
|
|
|
|
2020-09-07 11:16:41 +00:00
|
|
|
patchPhase = ''
|
|
|
|
substituteInPlace telethon/crypto/libssl.py --replace \
|
|
|
|
"ctypes.util.find_library('ssl')" "'${openssl.out}/lib/libssl.so'"
|
|
|
|
'';
|
|
|
|
|
2019-01-29 13:45:21 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
rsa
|
|
|
|
pyaes
|
|
|
|
];
|
|
|
|
|
|
|
|
# No tests available
|
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.5";
|
|
|
|
|
|
|
|
meta = with lib; {
|
2020-04-01 01:11:51 +00:00
|
|
|
homepage = "https://github.com/LonamiWebs/Telethon";
|
2019-01-29 13:45:21 +00:00
|
|
|
description = "Full-featured Telegram client library for Python 3";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ nyanloutre ];
|
|
|
|
};
|
|
|
|
}
|