1{ lib, fetchurl, pkg-config, buildPythonPackage, isPy3k, at-spi2-core, pygobject3, gnome, python }:
2
3buildPythonPackage rec {
4 pname = "pyatspi";
5 version = "2.46.0";
6 format = "other";
7
8 src = fetchurl {
9 url = "mirror://gnome/sources/${pname}/${lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
10 sha256 = "1FSJzz1HqhULGjXolJs7MQNfjCB15YjSa278Yllwxi4=";
11 };
12
13 nativeBuildInputs = [ pkg-config ];
14
15 buildInputs = [
16 at-spi2-core
17 pygobject3
18 ];
19
20 configureFlags = [
21 "PYTHON=${python.pythonOnBuildForHost.interpreter}"
22 ];
23
24 postPatch = ''
25 # useless python existence check for us
26 substituteInPlace configure \
27 --replace '&& ! which' '&& false'
28 '';
29
30 disabled = !isPy3k;
31
32 passthru = {
33 updateScript = gnome.updateScript {
34 packageName = pname;
35 attrPath = "python3.pkgs.${pname}";
36 versionPolicy = "odd-unstable";
37 };
38 };
39
40 meta = with lib; {
41 description = "Python client bindings for D-Bus AT-SPI";
42 homepage = "https://wiki.linuxfoundation.org/accessibility/d-bus";
43 license = licenses.gpl2;
44 maintainers = with maintainers; [ jtojnar ];
45 platforms = with platforms; unix;
46 };
47}