nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{
2 lib,
3 pkg-config,
4 fetchurl,
5 meson,
6 ninja,
7 wrapGAppsHook3,
8 gobject-introspection,
9 gettext,
10 yelp-tools,
11 itstool,
12 python3,
13 gtk3,
14 gnome,
15 replaceVars,
16 at-spi2-atk,
17 at-spi2-core,
18 dbus,
19 xkbcomp,
20 procps,
21 gnugrep,
22 coreutils,
23 gsettings-desktop-schemas,
24 speechd-minimal,
25 brltty,
26 liblouis,
27 gst_all_1,
28}:
29
30python3.pkgs.buildPythonApplication rec {
31 pname = "orca";
32 version = "48.6";
33
34 format = "other";
35
36 src = fetchurl {
37 url = "mirror://gnome/sources/orca/${lib.versions.major version}/orca-${version}.tar.xz";
38 hash = "sha256-7cUDRODf1yR2tcFLOqclyiaHGOpt2JvE7ib0ULM51pY=";
39 };
40
41 patches = [
42 (replaceVars ./fix-paths.patch {
43 cat = "${coreutils}/bin/cat";
44 grep = "${gnugrep}/bin/grep";
45 pgrep = "${procps}/bin/pgrep";
46 xkbcomp = "${xkbcomp}/bin/xkbcomp";
47 })
48 ];
49
50 nativeBuildInputs = [
51 meson
52 ninja
53 wrapGAppsHook3
54 pkg-config
55 gettext
56 yelp-tools
57 itstool
58 gobject-introspection
59 ];
60
61 pythonPath = with python3.pkgs; [
62 pygobject3
63 dbus-python
64 pyxdg
65 brltty
66 liblouis
67 psutil
68 speechd-minimal
69 gst-python
70 setproctitle
71 ];
72
73 strictDeps = false;
74
75 buildInputs = [
76 python3
77 gtk3
78 at-spi2-atk
79 at-spi2-core
80 dbus
81 gsettings-desktop-schemas
82 gst_all_1.gstreamer
83 gst_all_1.gst-plugins-base
84 gst_all_1.gst-plugins-good
85 ];
86
87 dontWrapGApps = true; # Prevent double wrapping
88
89 preFixup = ''
90 makeWrapperArgs+=("''${gappsWrapperArgs[@]}")
91 '';
92
93 passthru = {
94 updateScript = gnome.updateScript {
95 packageName = "orca";
96 };
97 };
98
99 meta = with lib; {
100 homepage = "https://orca.gnome.org/";
101 changelog = "https://gitlab.gnome.org/GNOME/orca/-/blob/main/NEWS";
102 description = "Screen reader";
103 mainProgram = "orca";
104 longDescription = ''
105 A free, open source, flexible and extensible screen reader that provides
106 access to the graphical desktop via speech and refreshable braille.
107 It works with applications and toolkits that support the Assistive
108 Technology Service Provider Interface (AT-SPI). That includes the GNOME
109 GTK toolkit, the Java platform's Swing toolkit, LibreOffice, Gecko, and
110 WebKitGtk. AT-SPI support for the KDE Qt toolkit is being pursued.
111
112 Needs `services.gnome.at-spi2-core.enable = true;` in `configuration.nix`.
113 '';
114 maintainers = with maintainers; [ berce ];
115 teams = [ teams.gnome ];
116 license = licenses.lgpl21;
117 platforms = platforms.linux;
118 };
119}