diff options
author | Doug Goldstein <cardoe@gentoo.org> | 2006-08-04 02:35:11 +0000 |
---|---|---|
committer | Doug Goldstein <cardoe@gentoo.org> | 2006-08-04 02:35:11 +0000 |
commit | 2afe27b82068d5a395184363f57fa5413925ebef (patch) | |
tree | 2f5f8e5180317e9ef4f0fb28a310a06c691dd344 /x11-libs/cairo | |
parent | Call java-pkg_pkg_setup() if necessary (bug #142708) (diff) | |
download | gentoo-2-2afe27b82068d5a395184363f57fa5413925ebef.tar.gz gentoo-2-2afe27b82068d5a395184363f57fa5413925ebef.tar.bz2 gentoo-2-2afe27b82068d5a395184363f57fa5413925ebef.zip |
Fixing bugs #139946, 140125, 142696
(Portage version: 2.1.1_pre3-r3)
Diffstat (limited to 'x11-libs/cairo')
-rw-r--r-- | x11-libs/cairo/ChangeLog | 10 | ||||
-rw-r--r-- | x11-libs/cairo/cairo-1.2.0-r1.ebuild | 69 | ||||
-rw-r--r-- | x11-libs/cairo/files/cairo-1.2.0-disappearing-text.patch | 94 | ||||
-rw-r--r-- | x11-libs/cairo/files/cairo-1.2.0-remove-flush.patch | 37 | ||||
-rw-r--r-- | x11-libs/cairo/files/digest-cairo-1.2.0-r1 | 3 |
5 files changed, 212 insertions, 1 deletions
diff --git a/x11-libs/cairo/ChangeLog b/x11-libs/cairo/ChangeLog index d73b67a894f6..759be6ecae07 100644 --- a/x11-libs/cairo/ChangeLog +++ b/x11-libs/cairo/ChangeLog @@ -1,6 +1,14 @@ # ChangeLog for x11-libs/cairo # Copyright 2000-2006 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/x11-libs/cairo/ChangeLog,v 1.77 2006/07/14 15:21:59 blubb Exp $ +# $Header: /var/cvsroot/gentoo-x86/x11-libs/cairo/ChangeLog,v 1.78 2006/08/04 02:35:11 cardoe Exp $ + +*cairo-1.2.0-r1 (04 Aug 2006) + + 04 Aug 2006; Doug Goldstein <cardoe@gentoo.org> + +files/cairo-1.2.0-disappearing-text.patch, + +files/cairo-1.2.0-remove-flush.patch, -cairo-1.2.0.ebuild, + +cairo-1.2.0-r1.ebuild: + Fixing bugs #139946, 140125, 142696 14 Jul 2006; Simon Stelling <blubb@gentoo.org> cairo-1.0.4.ebuild: RESTRICT test phase for latest stable too; bug 118106 diff --git a/x11-libs/cairo/cairo-1.2.0-r1.ebuild b/x11-libs/cairo/cairo-1.2.0-r1.ebuild new file mode 100644 index 000000000000..0c6618255256 --- /dev/null +++ b/x11-libs/cairo/cairo-1.2.0-r1.ebuild @@ -0,0 +1,69 @@ +# Copyright 1999-2006 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/x11-libs/cairo/cairo-1.2.0-r1.ebuild,v 1.1 2006/08/04 02:35:11 cardoe Exp $ + +inherit eutils flag-o-matic + +DESCRIPTION="A vector graphics library with cross-device output support" +HOMEPAGE="http://cairographics.org/" +SRC_URI="http://cairographics.org/releases/${P}.tar.gz" + +LICENSE="|| ( LGPL-2.1 MPL-1.1 )" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc-macos ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd" +IUSE="directfb doc glitz pdf png svg X" + +# Test causes a circular depend on gtk+... since gtk+ needs cairo but test needs gtk+ so we need to block it +RESTRICT="test" + +RDEPEND="media-libs/fontconfig + >=media-libs/freetype-2.1.4 + X? ( || ( + ( x11-libs/libXrender + x11-libs/libXext + x11-libs/libX11 ) + virtual/x11 + ) + virtual/xft + ) + directfb? ( >=dev-libs/DirectFB-0.9.24 ) + glitz? ( >=media-libs/glitz-0.5.1 ) + png? ( media-libs/libpng ) + svg? ( dev-libs/libxml2 ) + !<x11-libs/cairo-0.2" +DEPEND="${RDEPEND} + >=dev-util/pkgconfig-0.9 + X? ( || ( x11-proto/renderproto virtual/x11 ) ) + doc? ( >=dev-util/gtk-doc-1.3 + ~app-text/docbook-xml-dtd-4.2 )" + +src_unpack() { + unpack ${A} + cd ${S} + + epatch ${FILESDIR}/${P}-disappearing-text.patch + epatch ${FILESDIR}/${P}-remove-flush.patch +} + +src_compile() { + #gets rid of fbmmx.c inlining warnings + append-flags -finline-limit=1200 + + econf $(use_enable X xlib) $(use_enable doc gtk-doc) $(use_enable directfb) \ + $(use_enable png) $(use_enable svg) $(use_enable pdf) \ + $(use_enable glitz) --enable-freetype --enable-ps \ + || die "configure failed" + + emake || die "compile failed" +} + +src_install() { + make DESTDIR="${D}" install || die "Installation failed" + dodoc AUTHORS ChangeLog NEWS README TODO +} + +pkg_postinst() { + echo + ewarn "You will most likely need to run revdep-rebuild after emerging this" + echo +} diff --git a/x11-libs/cairo/files/cairo-1.2.0-disappearing-text.patch b/x11-libs/cairo/files/cairo-1.2.0-disappearing-text.patch new file mode 100644 index 000000000000..5bd59e611e76 --- /dev/null +++ b/x11-libs/cairo/files/cairo-1.2.0-disappearing-text.patch @@ -0,0 +1,94 @@ +From: Carl Worth <cworth@cworth.org> +Date: Wed, 26 Jul 2006 22:48:56 +0000 (-0700) +Subject: Elide size-zero glyphs from calls to XRender functions. +X-Git-Url: http://gitweb.freedesktop.org/?p=cairo;a=commitdiff;h=456cdb3058f3b416109a9600167cd8842300ae14 + +Elide size-zero glyphs from calls to XRender functions. + +There appears to be a bug in some X servers which is triggered by +rendering 1-bit glyphs with zero size via the functions +XRenderAddGlyphs and XRenderCompositeText8 (and likely its variants). + +We avoid this bug by making a copy of the glyphs array which does not +include any of the size-zero glyphs so that the X server never sees them. +--- + +--- a/src/cairo-xlib-surface.c ++++ b/src/cairo-xlib-surface.c +@@ -2674,12 +2674,13 @@ _cairo_xlib_surface_show_glyphs (void + cairo_surface_attributes_t attributes; + cairo_xlib_surface_t *src = NULL; + ++ cairo_glyph_t *output_glyphs; + const cairo_glyph_t *glyphs_chunk; + int glyphs_remaining, chunk_size, max_chunk_size; + cairo_scaled_glyph_t *scaled_glyph; + cairo_xlib_surface_font_private_t *font_private; + +- int i; ++ int i, o; + unsigned long max_index = 0; + + cairo_xlib_surface_show_glyphs_func_t show_glyphs_func; +@@ -2723,6 +2724,13 @@ _cairo_xlib_surface_show_glyphs (void + (font_private != NULL && font_private->dpy != dst->dpy)) + return CAIRO_INT_STATUS_UNSUPPORTED; + ++ /* We make a copy of the glyphs so that we can elide any size-zero ++ * glyphs to workaround an X server bug, (present in at least Xorg ++ * 7.1 without EXA). */ ++ output_glyphs = malloc (num_glyphs * sizeof (cairo_glyph_t)); ++ if (output_glyphs == NULL) ++ return CAIRO_STATUS_NO_MEMORY; ++ + /* After passing all those tests, we're now committed to rendering + * these glyphs or to fail trying. We first upload any glyphs to + * the X server that it doesn't have already, then we draw +@@ -2781,7 +2789,7 @@ _cairo_xlib_surface_show_glyphs (void + goto BAIL; + + /* Send all unsent glyphs to the server, and count the max of the glyph indices */ +- for (i = 0; i < num_glyphs; i++) { ++ for (i = 0, o = 0; i < num_glyphs; i++) { + if (glyphs[i].index > max_index) + max_index = glyphs[i].index; + status = _cairo_scaled_glyph_lookup (scaled_font, +@@ -2790,11 +2798,18 @@ _cairo_xlib_surface_show_glyphs (void + &scaled_glyph); + if (status != CAIRO_STATUS_SUCCESS) + goto BAIL; +- if (scaled_glyph->surface_private == NULL) { +- _cairo_xlib_surface_add_glyph (dst->dpy, scaled_font, scaled_glyph); +- scaled_glyph->surface_private = (void *) 1; ++ /* Don't put any size-zero glyphs into output_glyphs to avoid ++ * an X server bug which stops rendering glyphs after the ++ * first size-zero glyph. */ ++ if (scaled_glyph->surface->width && scaled_glyph->surface->height) { ++ output_glyphs[o++] = glyphs[i]; ++ if (scaled_glyph->surface_private == NULL) { ++ _cairo_xlib_surface_add_glyph (dst->dpy, scaled_font, scaled_glyph); ++ scaled_glyph->surface_private = (void *) 1; ++ } + } + } ++ num_glyphs = o; + + _cairo_xlib_surface_ensure_dst_picture (dst); + +@@ -2811,7 +2826,7 @@ _cairo_xlib_surface_show_glyphs (void + } + max_chunk_size /= sz_xGlyphElt; + +- for (glyphs_remaining = num_glyphs, glyphs_chunk = glyphs; ++ for (glyphs_remaining = num_glyphs, glyphs_chunk = output_glyphs; + glyphs_remaining; + glyphs_remaining -= chunk_size, glyphs_chunk += chunk_size) + { +@@ -2826,6 +2841,7 @@ _cairo_xlib_surface_show_glyphs (void + + BAIL: + _cairo_scaled_font_thaw_cache (scaled_font); ++ free (output_glyphs); + + if (src) + _cairo_pattern_release_surface (src_pattern, &src->base, &attributes); diff --git a/x11-libs/cairo/files/cairo-1.2.0-remove-flush.patch b/x11-libs/cairo/files/cairo-1.2.0-remove-flush.patch new file mode 100644 index 000000000000..10c054388fb0 --- /dev/null +++ b/x11-libs/cairo/files/cairo-1.2.0-remove-flush.patch @@ -0,0 +1,37 @@ +From: Vladimir Vukicevic <vladimir@pobox.com> +Date: Mon, 17 Jul 2006 18:33:47 +0000 (-0700) +Subject: [xlib] Remove XSync implementation of surface_flush +X-Git-Url: http://gitweb.freedesktop.org/?p=cairo;a=commitdiff;h=b7191885c88068dad57d68ced69a752d1162b12c + +[xlib] Remove XSync implementation of surface_flush + +Remove the xlib implementation of surface_flush which just called XSync +before. +--- + +--- a/src/cairo-xlib-surface.c ++++ b/src/cairo-xlib-surface.c +@@ -1722,14 +1722,6 @@ _cairo_xlib_surface_get_font_options (vo + *options = surface->screen_info->font_options; + } + +-static cairo_status_t +-_cairo_xlib_surface_flush (void *abstract_surface) +-{ +- cairo_xlib_surface_t *surface = abstract_surface; +- XSync (surface->dpy, False); +- return CAIRO_STATUS_SUCCESS; +-} +- + static void + _cairo_xlib_surface_scaled_font_fini (cairo_scaled_font_t *scaled_font); + +@@ -1756,7 +1748,7 @@ static const cairo_surface_backend_t cai + _cairo_xlib_surface_get_extents, + NULL, /* old_show_glyphs */ + _cairo_xlib_surface_get_font_options, +- _cairo_xlib_surface_flush, ++ NULL, /* flush */ + NULL, /* mark_dirty_rectangle */ + _cairo_xlib_surface_scaled_font_fini, + _cairo_xlib_surface_scaled_glyph_fini, diff --git a/x11-libs/cairo/files/digest-cairo-1.2.0-r1 b/x11-libs/cairo/files/digest-cairo-1.2.0-r1 new file mode 100644 index 000000000000..9afc5cb43bc6 --- /dev/null +++ b/x11-libs/cairo/files/digest-cairo-1.2.0-r1 @@ -0,0 +1,3 @@ +MD5 5c9ad71d1b582907eee0497b196689ef cairo-1.2.0.tar.gz 2659930 +RMD160 9dd76e43e881dfd3f20a81fc0f946e302ed7993c cairo-1.2.0.tar.gz 2659930 +SHA256 fa3dc63029bab324682231f75af167b9370458785312a97fd0c50bf2dbd1cf21 cairo-1.2.0.tar.gz 2659930 |