Add package at-spi2-core.

BUG=chromium:900288
TEST=1) emerge-veyron_minnie at-spi2-core; 2) emerge-eve at-spi2-core;
3) emerge-tatl at-spi2-core.
CQ-DEPEND=CL:1345316
Change-Id: Iefa6a0a255d86074d93d0d4f26b7017f39c69df8
Reviewed-on: https://chromium-review.googlesource.com/1347198
Commit-Ready: Tim Zheng <timzheng@chromium.org>
Tested-by: Tim Zheng <timzheng@chromium.org>
Reviewed-by: Chirantan Ekbote <chirantan@chromium.org>
diff --git a/app-accessibility/at-spi2-core/Manifest b/app-accessibility/at-spi2-core/Manifest
new file mode 100644
index 0000000..8bda21a
--- /dev/null
+++ b/app-accessibility/at-spi2-core/Manifest
@@ -0,0 +1 @@
+DIST at-spi2-core-2.24.1.tar.xz 452440 BLAKE2B 2e3e262d507dadbdb8fc5bb1bd60d3dbe8a9c2946228b6dc551d0a9564684d96b1b6cbe29849c1d846b3106b5444a2c6880a10825ba20cca87893f6a52815023 SHA512 e7f354a90204f12d4e464a6b4e4cb27141af3715d7c5ec253bdd2ebe65bc7d191ae7b775c45470a1bd1fe2c0accdd4e84feeb5e1eb1a6c05f3e5e734371027be
diff --git a/app-accessibility/at-spi2-core/at-spi2-core-2.24.1.ebuild b/app-accessibility/at-spi2-core/at-spi2-core-2.24.1.ebuild
new file mode 100644
index 0000000..38267bb
--- /dev/null
+++ b/app-accessibility/at-spi2-core/at-spi2-core-2.24.1.ebuild
@@ -0,0 +1,60 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+GNOME2_LA_PUNT="yes"
+
+inherit eutils gnome2 multilib-minimal
+
+DESCRIPTION="D-Bus accessibility specifications and registration daemon"
+HOMEPAGE="https://wiki.gnome.org/Accessibility"
+
+LICENSE="LGPL-2+"
+SLOT="2"
+IUSE="X +introspection"
+KEYWORDS="*"
+
+# x11-libs/libSM is needed until upstream #719808 is solved either
+# making the dep unneeded or fixing their configure
+# Only libX11 is optional right now
+RDEPEND="
+	>=dev-libs/glib-2.36:2[${MULTILIB_USEDEP}]
+	>=sys-apps/dbus-1[${MULTILIB_USEDEP}]
+	x11-libs/libSM[${MULTILIB_USEDEP}]
+	x11-libs/libXi[${MULTILIB_USEDEP}]
+	x11-libs/libXtst[${MULTILIB_USEDEP}]
+	introspection? ( >=dev-libs/gobject-introspection-0.9.6:= )
+	X? (
+		x11-libs/libX11[${MULTILIB_USEDEP}]
+		x11-libs/libXi[${MULTILIB_USEDEP}]
+		x11-libs/libXtst[${MULTILIB_USEDEP}]
+	)
+"
+DEPEND="${RDEPEND}
+	>=dev-util/gtk-doc-am-1.9
+	>=dev-util/intltool-0.40
+	sys-devel/gettext
+	virtual/pkgconfig[${MULTILIB_USEDEP}]
+"
+
+PATCHES=(
+	# disable teamspaces test since that requires Novell.ICEDesktop.Daemon
+	"${FILESDIR}/${PN}-2.0.2-disable-teamspaces-test.patch"
+)
+
+multilib_src_configure() {
+	# xevie is deprecated/broken since xorg-1.6/1.7
+	ECONF_SOURCE=${S} \
+	gnome2_src_configure \
+		--disable-xevie \
+		$(multilib_native_use_enable introspection) \
+		$(use_enable X x11)
+
+	# work-around gtk-doc out-of-source brokedness
+	if multilib_is_native_abi; then
+		ln -s "${S}"/doc/libatspi/html doc/libatspi/html || die
+	fi
+}
+
+multilib_src_compile() { gnome2_src_compile; }
+multilib_src_install() { gnome2_src_install; }
diff --git a/app-accessibility/at-spi2-core/files/at-spi2-core-2.0.2-disable-teamspaces-test.patch b/app-accessibility/at-spi2-core/files/at-spi2-core-2.0.2-disable-teamspaces-test.patch
new file mode 100644
index 0000000..269236d
--- /dev/null
+++ b/app-accessibility/at-spi2-core/files/at-spi2-core-2.0.2-disable-teamspaces-test.patch
@@ -0,0 +1,13 @@
+diff --git a/dbind/dbtest.c b/dbind/dbtest.c
+index e8bbb63..9843c3d 100644
+--- a/dbind/dbtest.c
++++ b/dbind/dbtest.c
+@@ -417,7 +417,7 @@ int main (int argc, char **argv)
+ 
+     test_helpers ();
+     test_marshalling ();
+-    test_teamspaces (bus);
++    /* test_teamspaces (bus); */
+ 
+     return 0;
+ }
diff --git a/app-accessibility/at-spi2-core/metadata.xml b/app-accessibility/at-spi2-core/metadata.xml
new file mode 100644
index 0000000..3998080
--- /dev/null
+++ b/app-accessibility/at-spi2-core/metadata.xml
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer type="project">
+	<email>gnome@gentoo.org</email>
+	<name>Gentoo GNOME Desktop</name>
+</maintainer>
+</pkgmetadata>