initial import
This commit is contained in:
130
gtk/optionalize-at-spi2-atk-dependency.patch
Normal file
130
gtk/optionalize-at-spi2-atk-dependency.patch
Normal file
@@ -0,0 +1,130 @@
|
||||
diff --git a/config.h.in b/config.h.in
|
||||
index d78b226..ac46f89 100644
|
||||
--- a/config.h.in
|
||||
+++ b/config.h.in
|
||||
@@ -10,6 +10,9 @@
|
||||
/* Disable deprecation warnings from glib */
|
||||
#undef GLIB_DISABLE_DEPRECATION_WARNINGS
|
||||
|
||||
+/* Define to use atk-bridge-2.0 */
|
||||
+#undef HAVE_ATK_BRIDGE
|
||||
+
|
||||
/* Define to 1 if you have the `bind_textdomain_codeset' function. */
|
||||
#undef HAVE_BIND_TEXTDOMAIN_CODESET
|
||||
|
||||
diff --git a/config.h.meson b/config.h.meson
|
||||
index 2af5547..fa08c23 100644
|
||||
--- a/config.h.meson
|
||||
+++ b/config.h.meson
|
||||
@@ -11,6 +11,9 @@
|
||||
/* Disable deprecation warnings from glib */
|
||||
#mesondefine GLIB_DISABLE_DEPRECATION_WARNINGS
|
||||
|
||||
+/* Define to use atk-bridge-2.0 */
|
||||
+#mesondefine HAVE_ATK_BRIDGE
|
||||
+
|
||||
/* Define to 1 if you have the `bind_textdomain_codeset' function. */
|
||||
#mesondefine HAVE_BIND_TEXTDOMAIN_CODESET
|
||||
|
||||
diff --git a/configure b/configure
|
||||
index 34d3410..92289a3 100755
|
||||
--- a/configure
|
||||
+++ b/configure
|
||||
@@ -1064,6 +1064,7 @@ enable_glibtest
|
||||
enable_modules
|
||||
with_included_immodules
|
||||
with_x
|
||||
+with_atk_bridge
|
||||
enable_win32_gles
|
||||
enable_cups
|
||||
enable_papi
|
||||
@@ -1844,6 +1845,7 @@ Optional Packages:
|
||||
--with-included-immodules=MODULE1,MODULE2,...
|
||||
build the specified input methods into gtk
|
||||
--with-x use the X Window System
|
||||
+ --without-atk-bridge Do not use AT-SPI ATK bridge
|
||||
--with-html-dir=PATH path to installed docs
|
||||
--with-xml-catalog=CATALOG
|
||||
path to xml catalog to use
|
||||
@@ -27048,8 +27050,20 @@ fi
|
||||
# Check for Accessibility Toolkit flags
|
||||
########################################
|
||||
|
||||
-if test x$enable_x11_backend = xyes; then
|
||||
+
|
||||
+# Check whether --with-atk-bridge was given.
|
||||
+if test "${with_atk_bridge+set}" = set; then :
|
||||
+ withval=$with_atk_bridge; :
|
||||
+else
|
||||
+ with_atk_bridge=$enable_x11_backend
|
||||
+fi
|
||||
+
|
||||
+
|
||||
+if test x$with_atk_bridge != xno; then
|
||||
ATK_PACKAGES="atk atk-bridge-2.0"
|
||||
+
|
||||
+$as_echo "#define HAVE_ATK_BRIDGE 1" >>confdefs.h
|
||||
+
|
||||
else
|
||||
ATK_PACKAGES="atk"
|
||||
fi
|
||||
diff --git a/gtk/a11y/gtkaccessibility.c b/gtk/a11y/gtkaccessibility.c
|
||||
index 7f0e520..f2ef2eb 100644
|
||||
--- a/gtk/a11y/gtkaccessibility.c
|
||||
+++ b/gtk/a11y/gtkaccessibility.c
|
||||
@@ -37,7 +37,7 @@
|
||||
#include <gtk/gtktogglebutton.h>
|
||||
#include <gtk/gtkaccessible.h>
|
||||
|
||||
-#ifdef GDK_WINDOWING_X11
|
||||
+#ifdef HAVE_ATK_BRIDGE
|
||||
#include <atk-bridge.h>
|
||||
#endif
|
||||
|
||||
@@ -988,7 +988,7 @@ _gtk_accessibility_init (void)
|
||||
_gtk_accessibility_override_atk_util ();
|
||||
do_window_event_initialization ();
|
||||
|
||||
-#ifdef GDK_WINDOWING_X11
|
||||
+#ifdef HAVE_ATK_BRIDGE
|
||||
atk_bridge_adaptor_init (NULL, NULL);
|
||||
#endif
|
||||
|
||||
diff --git a/meson.build b/meson.build
|
||||
index b2eaa33..ec4bd00 100644
|
||||
--- a/meson.build
|
||||
+++ b/meson.build
|
||||
@@ -576,7 +576,7 @@ if x11_enabled
|
||||
xfixes_dep = dependency('xfixes', required: false)
|
||||
xcomposite_dep = dependency('xcomposite', required: false)
|
||||
fontconfig_dep = dependency('fontconfig', fallback: ['fontconfig', 'fontconfig_dep'])
|
||||
- atkbridge_dep = dependency('atk-bridge-2.0', version: at_spi2_atk_req)
|
||||
+ atkbridge_dep = dependency('atk-bridge-2.0', version: at_spi2_atk_req, required: get_option('atk-bridge'))
|
||||
|
||||
x11_pkgs = ['fontconfig', 'x11', 'xext', 'xi', 'xrandr']
|
||||
|
||||
@@ -593,7 +593,10 @@ if x11_enabled
|
||||
x11_pkgs += ['xdamage']
|
||||
endif
|
||||
|
||||
- atk_pkgs += ['atk-bridge-2.0']
|
||||
+ if atkbridge_dep.found()
|
||||
+ atk_pkgs += ['atk-bridge-2.0']
|
||||
+ cdata.set('HAVE_ATK_BRIDGE', 1)
|
||||
+ endif
|
||||
|
||||
cdata.set('HAVE_XDAMAGE', xdamage_dep.found() ? 1 : false)
|
||||
cdata.set('HAVE_XCURSOR', xcursor_dep.found() ? 1 : false)
|
||||
diff --git a/meson_options.txt b/meson_options.txt
|
||||
index 4f605b4..a0f5b88 100644
|
||||
--- a/meson_options.txt
|
||||
+++ b/meson_options.txt
|
||||
@@ -11,6 +11,8 @@ option('quartz_backend', type: 'boolean', value: true,
|
||||
description : 'Enable the macOS gdk backend (only when building on macOS)')
|
||||
|
||||
# Optional dependencies
|
||||
+option('atk-bridge', type: 'boolean', value: 'true',
|
||||
+ description : 'Enable AT-SPI ATK bridge support')
|
||||
option('xinerama', type: 'combo', choices : ['yes', 'no', 'auto'], value : 'auto',
|
||||
description : 'Enable support for the Xinerama extension')
|
||||
option('cloudproviders', type: 'boolean', value: false,
|
||||
Reference in New Issue
Block a user