Gentoo Archives: gentoo-commits

From: Mart Raudsepp <leio@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: x11-libs/gtk+/
Date: Sat, 19 Jan 2019 14:09:38
Message-Id: 1547906889.f3ae090a89c15c5d33d62ab0880b605d51dae244.leio@gentoo
1 commit: f3ae090a89c15c5d33d62ab0880b605d51dae244
2 Author: Mart Raudsepp <leio <AT> gentoo <DOT> org>
3 AuthorDate: Sat Jan 19 14:06:15 2019 +0000
4 Commit: Mart Raudsepp <leio <AT> gentoo <DOT> org>
5 CommitDate: Sat Jan 19 14:08:09 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f3ae090a
7
8 x11-libs/gtk+: add patchset for GtkSwitch unicode glyphs fallback
9
10 .. and some more patches from current upstream gtk-3-24 branch.
11
12 Tries to avoid fallback glyphs on GtkSwitch harder by using different
13 unicode glyphs when the best ones aren't available in any of the
14 installed fonts (so the hex fallback would be shown).
15 Tweaks long text comboboxes to behave better on wayland.
16 Other changes should be without much consequence to us.
17
18 Package-Manager: Portage-2.3.52, Repoman-2.3.12
19 Signed-off-by: Mart Raudsepp <leio <AT> gentoo.org>
20
21 x11-libs/gtk+/Manifest | 1 +
22 x11-libs/gtk+/gtk+-3.24.3-r1.ebuild | 233 ++++++++++++++++++++++++++++++++++++
23 2 files changed, 234 insertions(+)
24
25 diff --git a/x11-libs/gtk+/Manifest b/x11-libs/gtk+/Manifest
26 index 7b2787f49f6..dca7aa91cd7 100644
27 --- a/x11-libs/gtk+/Manifest
28 +++ b/x11-libs/gtk+/Manifest
29 @@ -1,4 +1,5 @@
30 DIST gtk+-2.24.32-patchset-r1.tar.xz 13364 BLAKE2B 15e5429b11cc4ccef1bf44105c790b5325e833ab12f393fe718c06470b90f3e4004bea4b51076a725f4bb10bcfd0c48b7063d9b9b021919ad0367d1b981be980 SHA512 1a15dce7578a914585981426d2e5d1cc45866866a70c3f443d1867ab1c0c28fb279bde6c3117b28eec2758a62c1b54bb6fb1b382ad6e9a7cf0114b13f2afd858
31 DIST gtk+-2.24.32.tar.xz 12620860 BLAKE2B 03f4c0a8be98473f62bc8c86859937969c4169960a5f93d37ff6dcde00413215fa6c7125b15781bf50d67b40aa0056cb71b83fb50acb2c3467b5deb3c8d938f0 SHA512 8e8fd9ae32f1d6fb544da260f00599f0f05090d910d767b06ef086ab4f1f8373a29bb0da9767761c9b5f4cfd51b5c45d0fa5d39b0428c839ddf0a579df806696
32 DIST gtk+-3.24.1.tar.xz 19307612 BLAKE2B f09b7cb252898b7290a3806f8fb579b706fc0ecd021817e34e71b101a7d222604b395c850c559f3ff0c38e0848abdffc483efe65f086357532be85db872028e7 SHA512 13ddb1099a2a0eb44ea53fa4be5054a403e1b27468a33862646ba111577b7bb72b9bbe4f6aea15889c2a2bee1238023bc23524b901cf2dbb3adf0e126eb6ea5d
33 +DIST gtk+-3.24.3-patchset-20190119.tar.xz 18032 BLAKE2B 2597fcac94f365fab4b02d73318ed4d65522befe1daf0e1a72578b4ead00cfc83da2215965a8afe869b4cc011eb173b0a5db0768903b6b793a1ec9848cadf325 SHA512 9fbd73936931e2e529146d74711a5243a5e67e49de2d63d9f4a64c1f0825cbdd50ae2683869e4616f5fd8a4267ac5bf68d3cd21a06589a9d3f14ce82e3573521
34 DIST gtk+-3.24.3.tar.xz 21099144 BLAKE2B d0493a720b310ebba3b64b643ccf3880ed1611418127a6997d885638b46f1f44e3a0b01651319d0fe476906a53fbee0f84ca1ba142aaa634a01841ce9c7e7efc SHA512 72a69d71f2e16a1dd169cc74d568da47131bd5d77994bcdd3b427ec1cd37c5daf0841a6e4824b125d860bc1c4f07c9835a3b2e74d951666253d3e4edbed0e5fc
35
36 diff --git a/x11-libs/gtk+/gtk+-3.24.3-r1.ebuild b/x11-libs/gtk+/gtk+-3.24.3-r1.ebuild
37 new file mode 100644
38 index 00000000000..917c556475c
39 --- /dev/null
40 +++ b/x11-libs/gtk+/gtk+-3.24.3-r1.ebuild
41 @@ -0,0 +1,233 @@
42 +# Copyright 1999-2019 Gentoo Authors
43 +# Distributed under the terms of the GNU General Public License v2
44 +
45 +EAPI=6
46 +GNOME2_LA_PUNT="yes"
47 +GNOME2_EAUTORECONF="yes"
48 +
49 +inherit flag-o-matic gnome2 multilib virtualx multilib-minimal
50 +
51 +DESCRIPTION="Gimp ToolKit +"
52 +HOMEPAGE="https://www.gtk.org/"
53 +SRC_URI+=" https://dev.gentoo.org/~leio/distfiles/${P}-patchset-20190119.tar.xz"
54 +
55 +LICENSE="LGPL-2+"
56 +SLOT="3"
57 +IUSE="aqua broadway cloudprint colord cups examples gtk-doc +introspection test vim-syntax wayland +X xinerama"
58 +REQUIRED_USE="
59 + || ( aqua wayland X )
60 + xinerama? ( X )
61 +"
62 +
63 +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
64 +
65 +# Upstream wants us to do their job:
66 +# https://bugzilla.gnome.org/show_bug.cgi?id=768662#c1
67 +RESTRICT="test"
68 +
69 +# FIXME: introspection data is built against system installation of gtk+:3,
70 +# bug #????
71 +COMMON_DEPEND="
72 + >=dev-libs/atk-2.15[introspection?,${MULTILIB_USEDEP}]
73 + >=dev-libs/glib-2.53.4:2[${MULTILIB_USEDEP}]
74 + media-libs/fontconfig[${MULTILIB_USEDEP}]
75 + >=media-libs/libepoxy-1.4[X(+)?,${MULTILIB_USEDEP}]
76 + >=x11-libs/cairo-1.14[aqua?,glib,svg,X?,${MULTILIB_USEDEP}]
77 + >=x11-libs/gdk-pixbuf-2.30:2[introspection?,${MULTILIB_USEDEP}]
78 + >=x11-libs/pango-1.41.0[introspection?,${MULTILIB_USEDEP}]
79 + >=media-libs/harfbuzz-0.9:=
80 + x11-misc/shared-mime-info
81 +
82 + cloudprint? (
83 + >=net-libs/rest-0.7[${MULTILIB_USEDEP}]
84 + >=dev-libs/json-glib-1.0[${MULTILIB_USEDEP}] )
85 + colord? ( >=x11-misc/colord-0.1.9:0=[${MULTILIB_USEDEP}] )
86 + cups? ( >=net-print/cups-1.2[${MULTILIB_USEDEP}] )
87 + introspection? ( >=dev-libs/gobject-introspection-1.39:= )
88 + wayland? (
89 + >=dev-libs/wayland-1.9.91[${MULTILIB_USEDEP}]
90 + >=dev-libs/wayland-protocols-1.12
91 + media-libs/mesa[wayland,${MULTILIB_USEDEP}]
92 + >=x11-libs/libxkbcommon-0.2[${MULTILIB_USEDEP}]
93 + )
94 + X? (
95 + >=app-accessibility/at-spi2-atk-2.5.3[${MULTILIB_USEDEP}]
96 + x11-libs/libX11[${MULTILIB_USEDEP}]
97 + >=x11-libs/libXi-1.3[${MULTILIB_USEDEP}]
98 + x11-libs/libXext[${MULTILIB_USEDEP}]
99 + >=x11-libs/libXrandr-1.5[${MULTILIB_USEDEP}]
100 + x11-libs/libXcursor[${MULTILIB_USEDEP}]
101 + x11-libs/libXfixes[${MULTILIB_USEDEP}]
102 + x11-libs/libXcomposite[${MULTILIB_USEDEP}]
103 + x11-libs/libXdamage[${MULTILIB_USEDEP}]
104 + xinerama? ( x11-libs/libXinerama[${MULTILIB_USEDEP}] )
105 + )
106 +"
107 +DEPEND="${COMMON_DEPEND}
108 + app-text/docbook-xsl-stylesheets
109 + app-text/docbook-xml-dtd:4.1.2
110 + dev-libs/libxslt
111 + dev-libs/gobject-introspection-common
112 + >=dev-util/gdbus-codegen-2.48
113 + dev-util/glib-utils
114 + >=dev-util/gtk-doc-am-1.20
115 + gtk-doc? ( >=dev-util/gtk-doc-1.20 )
116 + >=sys-devel/gettext-0.19.7[${MULTILIB_USEDEP}]
117 + virtual/pkgconfig[${MULTILIB_USEDEP}]
118 + X? ( x11-base/xorg-proto )
119 + test? (
120 + media-fonts/font-misc-misc
121 + media-fonts/font-cursor-misc )
122 +"
123 +# gtk+-3.2.2 breaks Alt key handling in <=x11-libs/vte-0.30.1:2.90
124 +# gtk+-3.3.18 breaks scrolling in <=x11-libs/vte-0.31.0:2.90
125 +RDEPEND="${COMMON_DEPEND}
126 + >=dev-util/gtk-update-icon-cache-3
127 + !<gnome-base/gail-1000
128 + !<x11-libs/vte-0.31.0:2.90
129 +"
130 +# librsvg for svg icons (PDEPEND to avoid circular dep), bug #547710
131 +PDEPEND="
132 + gnome-base/librsvg[${MULTILIB_USEDEP}]
133 + >=x11-themes/adwaita-icon-theme-3.14
134 + vim-syntax? ( app-vim/gtk-syntax )
135 +"
136 +
137 +MULTILIB_CHOST_TOOLS=(
138 + /usr/bin/gtk-query-immodules-3.0$(get_exeext)
139 +)
140 +
141 +strip_builddir() {
142 + local rule=$1
143 + shift
144 + local directory=$1
145 + shift
146 + sed -e "s/^\(${rule} =.*\)${directory}\(.*\)$/\1\2/" -i $@ \
147 + || die "Could not strip director ${directory} from build."
148 +}
149 +
150 +src_prepare() {
151 + if ! use test ; then
152 + # don't waste time building tests
153 + strip_builddir SRC_SUBDIRS testsuite Makefile.{am,in}
154 +
155 + # the tests dir needs to be build now because since commit
156 + # 7ff3c6df80185e165e3bf6aa31bd014d1f8bf224 tests/gtkgears.o needs to be there
157 + # strip_builddir SRC_SUBDIRS tests Makefile.{am,in}
158 + fi
159 +
160 + if ! use examples; then
161 + # don't waste time building demos
162 + strip_builddir SRC_SUBDIRS demos Makefile.{am,in}
163 + strip_builddir SRC_SUBDIRS examples Makefile.{am,in}
164 + fi
165 +
166 + # Patches from gtk-3-24 branch up to b984074e2924b7e759, mainly fixing GtkSwitch glyphs when IEC power symbol unicode-9 glyphs are missing from all installed fonts
167 + eapply "${WORKDIR}"/patches
168 +
169 + # gtk-update-icon-cache is installed by dev-util/gtk-update-icon-cache
170 + eapply "${FILESDIR}"/${PN}-3.22.2-update-icon-cache.patch
171 +
172 + # Fix broken autotools logic
173 + eapply "${FILESDIR}"/${PN}-3.22.20-libcloudproviders-automagic.patch
174 +
175 + gnome2_src_prepare
176 +}
177 +
178 +multilib_src_configure() {
179 + # need libdir here to avoid a double slash in a path that libtool doesn't
180 + # grok so well during install (// between $EPREFIX and usr ...)
181 + # cloudprovider is not packaged in Gentoo
182 + ECONF_SOURCE=${S} \
183 + gnome2_src_configure \
184 + $(use_enable aqua quartz-backend) \
185 + $(use_enable broadway broadway-backend) \
186 + $(use_enable cloudprint) \
187 + $(use_enable colord) \
188 + $(use_enable cups cups auto) \
189 + $(multilib_native_use_enable gtk-doc) \
190 + $(multilib_native_use_enable introspection) \
191 + $(use_enable wayland wayland-backend) \
192 + $(use_enable X x11-backend) \
193 + $(use_enable X xcomposite) \
194 + $(use_enable X xdamage) \
195 + $(use_enable X xfixes) \
196 + $(use_enable X xkb) \
197 + $(use_enable X xrandr) \
198 + $(use_enable xinerama) \
199 + --disable-cloudproviders \
200 + --disable-mir-backend \
201 + --disable-papi \
202 + --enable-man \
203 + --with-xml-catalog="${EPREFIX}"/etc/xml/catalog \
204 + --libdir="${EPREFIX}"/usr/$(get_libdir) \
205 + CUPS_CONFIG="${EPREFIX}/usr/bin/${CHOST}-cups-config"
206 +
207 + # work-around gtk-doc out-of-source brokedness
208 + if multilib_is_native_abi; then
209 + local d
210 + for d in gdk gtk libgail-util; do
211 + ln -s "${S}"/docs/reference/${d}/html docs/reference/${d}/html || die
212 + done
213 + fi
214 +}
215 +
216 +multilib_src_test() {
217 + "${EROOT}${GLIB_COMPILE_SCHEMAS}" --allow-any-name "${S}/gtk" || die
218 + GSETTINGS_SCHEMA_DIR="${S}/gtk" virtx emake check
219 +}
220 +
221 +multilib_src_install() {
222 + gnome2_src_install
223 +}
224 +
225 +multilib_src_install_all() {
226 + insinto /etc/gtk-3.0
227 + doins "${FILESDIR}"/settings.ini
228 + # Skip README.{in,commits,win32} and useless ChangeLog that would get installed by default
229 + DOCS=( AUTHORS NEWS README )
230 + einstalldocs
231 +}
232 +
233 +pkg_preinst() {
234 + gnome2_pkg_preinst
235 +
236 + multilib_pkg_preinst() {
237 + # Make immodules.cache belongs to gtk+ alone
238 + local cache="usr/$(get_libdir)/gtk-3.0/3.0.0/immodules.cache"
239 +
240 + if [[ -e ${EROOT}${cache} ]]; then
241 + cp "${EROOT}"${cache} "${ED}"/${cache} || die
242 + else
243 + touch "${ED}"/${cache} || die
244 + fi
245 + }
246 + multilib_parallel_foreach_abi multilib_pkg_preinst
247 +}
248 +
249 +pkg_postinst() {
250 + gnome2_pkg_postinst
251 +
252 + multilib_pkg_postinst() {
253 + gnome2_query_immodules_gtk3 \
254 + || die "Update immodules cache failed (for ${ABI})"
255 + }
256 + multilib_parallel_foreach_abi multilib_pkg_postinst
257 +
258 + if ! has_version "app-text/evince"; then
259 + elog "Please install app-text/evince for print preview functionality."
260 + elog "Alternatively, check \"gtk-print-preview-command\" documentation and"
261 + elog "add it to your settings.ini file."
262 + fi
263 +}
264 +
265 +pkg_postrm() {
266 + gnome2_pkg_postrm
267 +
268 + if [[ -z ${REPLACED_BY_VERSION} ]]; then
269 + multilib_pkg_postrm() {
270 + rm -f "${EROOT}"usr/$(get_libdir)/gtk-3.0/3.0.0/immodules.cache
271 + }
272 + multilib_foreach_abi multilib_pkg_postrm
273 + fi
274 +}