2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchPypi,
|
|
|
|
python,
|
|
|
|
cffi,
|
|
|
|
pkg-config,
|
|
|
|
libxkbcommon,
|
|
|
|
pytestCheckHook,
|
2021-12-06 16:07:01 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "xkbcommon";
|
2024-07-27 06:49:29 +00:00
|
|
|
version = "1.5.1";
|
2024-01-02 11:29:13 +00:00
|
|
|
format = "setuptools";
|
2021-12-06 16:07:01 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2024-07-27 06:49:29 +00:00
|
|
|
hash = "sha256-rBdICNv2HTXZ2oBL8zuqx0vG8r4MEIWUrpPHnNFd3DY=";
|
2021-12-06 16:07:01 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [ pkg-config ];
|
|
|
|
propagatedNativeBuildInputs = [ cffi ];
|
|
|
|
buildInputs = [ libxkbcommon ];
|
|
|
|
propagatedBuildInputs = [ cffi ];
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [ pytestCheckHook ];
|
2021-12-06 16:07:01 +00:00
|
|
|
|
|
|
|
postBuild = ''
|
2023-11-16 04:20:00 +00:00
|
|
|
${python.pythonOnBuildForHost.interpreter} xkbcommon/ffi_build.py
|
2021-12-06 16:07:01 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "xkbcommon" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
homepage = "https://github.com/sde1000/python-xkbcommon";
|
|
|
|
description = "Python bindings for libxkbcommon using cffi";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ chvp ];
|
|
|
|
};
|
|
|
|
}
|