11 lib.meta.availableOn stdenv.hostPlatform gobject-introspection
12 && stdenv.hostPlatform.emulatorAvailable buildPackages,
13 gsettings-desktop-schemas,
25 systemdSupport ? lib.meta.availableOn stdenv.hostPlatform systemd,
28 stdenv.mkDerivation rec {
29 pname = "at-spi2-core";
36 separateDebugInfo = true;
39 url = "mirror://gnome/sources/${pname}/${lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
40 hash = "sha256-1+7n51vt3MJyztwrYFNWAPOq5uSBWJ68Znr8Q3wKYHk=";
51 ++ lib.optionals withIntrospection [
59 # at-spi2-core can be build without X support, but due it is a client-side library, GUI-less usage is a very rare case
62 # libXext is a transitive dependency of libXi
65 ++ lib.optionals systemdSupport [
66 # libsystemd is a needed for dbus-broker support
70 # In atspi-2.pc dbus-1 glib-2.0
71 # In atk.pc gobject-2.0
72 propagatedBuildInputs = [
77 # fails with "AT-SPI: Couldn't connect to accessibility bus. Is at-spi-bus-launcher running?"
82 # Provide dbus-daemon fallback when it is not already running when
83 # at-spi2-bus-launcher is executed. This allows us to avoid
84 # including the entire dbus closure in libraries linked with
85 # the at-spi2-core libraries.
86 "-Ddbus_daemon=/run/current-system/sw/bin/dbus-daemon"
88 ++ lib.optionals systemdSupport [
89 # Same as the above, but for dbus-broker
90 "-Ddbus_broker=/run/current-system/sw/bin/dbus-broker-launch"
92 ++ lib.optionals (!systemdSupport) [
97 updateScript = gnome.updateScript {
99 versionPolicy = "odd-unstable";
104 # Cannot use wrapGAppsHook'due to a dependency cycle
105 wrapProgram $out/libexec/at-spi-bus-launcher \
106 --prefix GIO_EXTRA_MODULES : "${lib.getLib dconf}/lib/gio/modules" \
107 --prefix XDG_DATA_DIRS : ${gsettings-desktop-schemas}/share/gsettings-schemas/${gsettings-desktop-schemas.name}
111 description = "Assistive Technology Service Provider Interface protocol definitions and daemon for D-Bus";
112 homepage = "https://gitlab.gnome.org/GNOME/at-spi2-core";
113 license = licenses.lgpl21Plus;
114 maintainers = teams.gnome.members ++ (with maintainers; [ raskin ]);
115 platforms = platforms.unix;