2021-02-24 18:30:23 +00:00
|
|
|
{ lib, buildPythonPackage, isPy3k, olm
|
|
|
|
, cffi, future, typing }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
buildPythonPackage {
|
|
|
|
pname = "python-olm";
|
|
|
|
inherit (olm) src version;
|
|
|
|
|
2022-06-26 10:26:21 +00:00
|
|
|
disabled = !isPy3k;
|
|
|
|
|
2021-02-24 18:30:23 +00:00
|
|
|
sourceRoot = "source/python";
|
2020-04-24 23:36:52 +00:00
|
|
|
buildInputs = [ olm ];
|
|
|
|
|
|
|
|
preBuild = ''
|
|
|
|
make include/olm/olm.h
|
|
|
|
'';
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
cffi
|
|
|
|
future
|
2022-06-26 10:26:21 +00:00
|
|
|
typing
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-12-06 16:07:01 +00:00
|
|
|
propagatedNativeBuildInputs = [
|
|
|
|
cffi
|
|
|
|
];
|
|
|
|
|
2021-02-24 18:30:23 +00:00
|
|
|
# Some required libraries for testing are not packaged yet.
|
2020-04-24 23:36:52 +00:00
|
|
|
doCheck = false;
|
2021-02-24 18:30:23 +00:00
|
|
|
pythonImportsCheck = [ "olm" ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-02-24 18:30:23 +00:00
|
|
|
meta = {
|
|
|
|
inherit (olm.meta) license maintainers;
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Python bindings for Olm";
|
|
|
|
homepage = "https://gitlab.matrix.org/matrix-org/olm/tree/master/python";
|
|
|
|
};
|
|
|
|
}
|