| -rw-r--r-- | x11-libs/cairo/Manifest | 4 | ||||
| -rw-r--r-- | x11-libs/cairo/cairo-9999.ebuild | 21 | ||||
| -rw-r--r-- | x11-libs/cairo/files/22336.patch | 113 |
3 files changed, 39 insertions, 99 deletions
diff --git a/x11-libs/cairo/Manifest b/x11-libs/cairo/Manifest index 24621ba..be1313d 100644 --- a/x11-libs/cairo/Manifest +++ b/x11-libs/cairo/Manifest @@ -1,2 +1,2 @@ -AUX 22336.patch 37911 RMD160 c559f8fd652d934bd8ed2f335b017bc6f8e6e6a1 SHA1 995dbecce96f10bb825ccbde8e558a682328bc00 SHA256 ad8177531d4b7ffa8d6016fa0057a722c769d744df5c546c1d876ced58d6cacc -EBUILD cairo-9999.ebuild 2710 RMD160 44f201bfe7bedee1177666695827b4c1e36e1081 SHA1 0302eb4b9513023348e28c7afb7bfafce2b157a0 SHA256 9942aad76f95d1651356f7502b1ef6507a08c1dab5801ebfeb93b88c334d02d7 +AUX 22336.patch 36091 RMD160 b9d6f94e93f0951e5a449fc4f220aa118a00e383 SHA1 793079f3867c560eb31881112818209006d212a9 SHA256 ef526f3234599e154a0099dd5d613577e468523a75d900fd43aef821a8bf10d2 +EBUILD cairo-9999.ebuild 2386 RMD160 9fa369bb4189bcc084a53fbd89317049f025af6a SHA1 6b6d4070abc02475cf396e2c52b55b10f2a3d178 SHA256 ecddd499685e72822ae7b944383c3ac4df3da8d0639b85271638633d00b942f6 diff --git a/x11-libs/cairo/cairo-9999.ebuild b/x11-libs/cairo/cairo-9999.ebuild index f375dee..d699d3c 100644 --- a/x11-libs/cairo/cairo-9999.ebuild +++ b/x11-libs/cairo/cairo-9999.ebuild @@ -14,7 +14,7 @@ SRC_URI="" LICENSE="|| ( LGPL-2.1 MPL-1.1 )" SLOT="0" KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd" -IUSE="+cairoscript +cleartype debug directfb doc glitz opengl sdl svg X xcb" +IUSE="+cairoscript +cleartype debug directfb doc dri glitz opengl openvg qt sdl svg X xcb" # Test causes a circular depend on gtk+... since gtk+ needs cairo but test needs gtk+ so we need to block it RESTRICT="test" @@ -26,6 +26,7 @@ RDEPEND="media-libs/fontconfig >=x11-libs/pixman-0.12.0 directfb? ( >=dev-libs/DirectFB-0.9.24 ) glitz? ( >=media-libs/glitz-0.5.1 ) + qt? ( x11-libs/qt ) svg? ( dev-libs/libxml2 ) X? ( >=x11-libs/libXrender-0.6 x11-libs/libXext @@ -54,7 +55,7 @@ DEPEND="${RDEPEND} src_prepare() { # ClearType-like patches applied by ArchLinux use cleartype && epatch "${FILESDIR}"/22336.patch - ./autogen.sh + ./autogen.sh --help eautoreconf # We need to run elibtoolize to ensure correct so versioning on FreeBSD @@ -70,9 +71,10 @@ src_configure() { fi econf $(use_enable X xlib) $(use_enable doc gtk-doc) \ - $(use_enable directfb) $(use_enable xcb) \ + $(use_enable directfb) $(use_enable xcb) $(use_enable qt) \ $(use_enable svg) $(use_enable glitz) $(use_enable X xlib-xrender) \ - $(use_enable cairoscript script) \ + $(use_enable cairoscript script) $(use_enable opengl gl)\ + $(use_enable dri drm) \ $(use_enable debug test-surfaces) --enable-pdf --enable-png \ --enable-ft --enable-ps \ || die "configure failed" @@ -82,14 +84,3 @@ src_install() { make DESTDIR="${D}" install || die "Installation failed" dodoc AUTHORS ChangeLog NEWS README } - -pkg_postinst() { - if use xcb; then - ewarn "You have enabled the Cairo XCB backend which is used only by" - ewarn "a select few apps. The Cairo XCB backend is presently" - ewarn "un-maintained and needs a lot of work to get it caught up" - ewarn "to the Xrender and Xlib backends, which are the backends used" - ewarn "by most applications. See:" - ewarn "http://lists.freedesktop.org/archives/xcb/2008-December/004139.html" - fi -} diff --git a/x11-libs/cairo/files/22336.patch b/x11-libs/cairo/files/22336.patch index 0170508..51bd8e2 100644 --- a/x11-libs/cairo/files/22336.patch +++ b/x11-libs/cairo/files/22336.patch @@ -1,5 +1,5 @@ diff --git a/src/cairo-font-options.c b/src/cairo-font-options.c -index dedd337..64a8911 100644 +index b2cb230..1f43528 100644 --- a/src/cairo-font-options.c +++ b/src/cairo-font-options.c @@ -39,6 +39,7 @@ @@ -103,10 +103,10 @@ index dedd337..64a8911 100644 * @options: a #cairo_font_options_t * @hint_style: the new hint style diff --git a/src/cairo-ft-font.c b/src/cairo-ft-font.c -index 17699de..aaf8620 100644 +index 26f4a83..d71ed34 100644 --- a/src/cairo-ft-font.c +++ b/src/cairo-ft-font.c -@@ -57,6 +57,30 @@ +@@ -59,6 +59,30 @@ #include FT_SYNTHESIS_H #endif @@ -137,7 +137,7 @@ index 17699de..aaf8620 100644 #define DOUBLE_TO_26_6(d) ((FT_F26Dot6)((d) * 64.0)) #define DOUBLE_FROM_26_6(t) ((double)(t) / 64.0) #define DOUBLE_TO_16_16(d) ((FT_Fixed)((d) * 65536.0)) -@@ -168,6 +192,25 @@ typedef struct _cairo_ft_unscaled_font_map { +@@ -174,6 +198,25 @@ typedef struct _cairo_ft_unscaled_font_map { int num_open_faces; } cairo_ft_unscaled_font_map_t; @@ -163,7 +163,7 @@ index 17699de..aaf8620 100644 static cairo_ft_unscaled_font_map_t *cairo_ft_unscaled_font_map = NULL; static void -@@ -746,6 +789,282 @@ _cairo_ft_unscaled_font_set_scale (cairo_ft_unscaled_font_t *unscaled, +@@ -773,6 +816,282 @@ _cairo_ft_unscaled_font_set_scale (cairo_ft_unscaled_font_t *unscaled, return CAIRO_STATUS_SUCCESS; } @@ -446,7 +446,7 @@ index 17699de..aaf8620 100644 /* Empirically-derived subpixel filtering values thanks to Keith * Packard and libXft. */ static const int filters[3][3] = { -@@ -775,7 +1094,6 @@ _get_bitmap_surface (FT_Bitmap *bitmap, +@@ -802,7 +1121,6 @@ _get_bitmap_surface (FT_Bitmap *bitmap, int width, height, stride; unsigned char *data; int format = CAIRO_FORMAT_A8; @@ -454,7 +454,7 @@ index 17699de..aaf8620 100644 width = bitmap->width; height = bitmap->rows; -@@ -817,7 +1135,7 @@ _get_bitmap_surface (FT_Bitmap *bitmap, +@@ -844,7 +1162,7 @@ _get_bitmap_surface (FT_Bitmap *bitmap, #ifndef WORDS_BIGENDIAN { @@ -463,7 +463,7 @@ index 17699de..aaf8620 100644 int count = stride * height; while (count--) { -@@ -844,108 +1162,115 @@ _get_bitmap_surface (FT_Bitmap *bitmap, +@@ -871,108 +1189,115 @@ _get_bitmap_surface (FT_Bitmap *bitmap, data = _cairo_malloc_ab (height, stride); if (!data) return _cairo_error (CAIRO_STATUS_NO_MEMORY); @@ -670,7 +670,7 @@ index 17699de..aaf8620 100644 } break; case FT_PIXEL_MODE_GRAY2: -@@ -966,7 +1291,7 @@ _get_bitmap_surface (FT_Bitmap *bitmap, +@@ -993,7 +1318,7 @@ _get_bitmap_surface (FT_Bitmap *bitmap, return (*surface)->base.status; } @@ -679,7 +679,7 @@ index 17699de..aaf8620 100644 pixman_image_set_component_alpha ((*surface)->pixman_image, TRUE); _cairo_image_surface_assume_ownership_of_data ((*surface)); -@@ -994,16 +1319,67 @@ _render_glyph_outline (FT_Face face, +@@ -1023,16 +1348,67 @@ _render_glyph_outline (FT_Face face, cairo_font_options_t *font_options, cairo_image_surface_t **surface) { @@ -752,7 +752,7 @@ index 17699de..aaf8620 100644 FT_Outline_Get_CBox (outline, &cbox); -@@ -1014,20 +1390,21 @@ _render_glyph_outline (FT_Face face, +@@ -1043,20 +1419,21 @@ _render_glyph_outline (FT_Face face, width = (unsigned int) ((cbox.xMax - cbox.xMin) >> 6); height = (unsigned int) ((cbox.yMax - cbox.yMin) >> 6); @@ -780,7 +780,7 @@ index 17699de..aaf8620 100644 default: format = CAIRO_FORMAT_A8; break; -@@ -1037,75 +1414,142 @@ _render_glyph_outline (FT_Face face, +@@ -1066,75 +1443,142 @@ _render_glyph_outline (FT_Face face, cairo_image_surface_create_for_data (NULL, format, 0, 0, 0); if ((*surface)->base.status) return (*surface)->base.status; @@ -884,13 +884,13 @@ index 17699de..aaf8620 100644 + bitmap.pixel_mode = FT_PIXEL_MODE_MONO; + bitmap.num_grays = 1; + stride = ((width + 31) & -32) >> 3; -+ break; + break; + case CAIRO_ANTIALIAS_DEFAULT: + case CAIRO_ANTIALIAS_GRAY: + bitmap.pixel_mode = FT_PIXEL_MODE_GRAY; + bitmap.num_grays = 256; + stride = (width + 3) & -4; - break; ++ break; + case CAIRO_ANTIALIAS_SUBPIXEL: + switch (font_options->subpixel_order) { + case CAIRO_SUBPIXEL_ORDER_RGB: @@ -976,7 +976,7 @@ index 17699de..aaf8620 100644 return CAIRO_STATUS_SUCCESS; } -@@ -1322,9 +1766,10 @@ _get_pattern_ft_options (FcPattern *pattern, cairo_ft_options_t *ret) +@@ -1351,9 +1795,10 @@ _get_pattern_ft_options (FcPattern *pattern, cairo_ft_options_t *ret) if (FcPatternGetBool (pattern, FC_ANTIALIAS, 0, &antialias) != FcResultMatch) antialias = FcTrue; @@ -988,12 +988,10 @@ index 17699de..aaf8620 100644 /* disable hinting if requested */ if (FcPatternGetBool (pattern, -@@ -1360,8 +1805,27 @@ _get_pattern_ft_options (FcPattern *pattern, cairo_ft_options_t *ret) +@@ -1389,6 +1834,25 @@ _get_pattern_ft_options (FcPattern *pattern, cairo_ft_options_t *ret) ft_options.base.antialias = CAIRO_ANTIALIAS_SUBPIXEL; } --#ifdef FC_HINT_STYLE -- if (FcPatternGetInteger (pattern, + if (FcPatternGetInteger (pattern, + FC_LCD_FILTER, 0, &lcd_filter) == FcResultMatch) + { @@ -1013,30 +1011,10 @@ index 17699de..aaf8620 100644 + } + } + -+#ifdef FC_HINT_STYLE -+ if (FcPatternGetInteger (pattern, + #ifdef FC_HINT_STYLE + if (FcPatternGetInteger (pattern, FC_HINT_STYLE, 0, &hintstyle) != FcResultMatch) - hintstyle = FC_HINT_FULL; - -@@ -1370,7 +1834,7 @@ _get_pattern_ft_options (FcPattern *pattern, cairo_ft_options_t *ret) - - switch (hintstyle) { - case FC_HINT_NONE: -- ft_options.base.hint_style = CAIRO_HINT_STYLE_NONE; -+ ft_options.base.hint_style = CAIRO_HINT_STYLE_NONE; - break; - case FC_HINT_SLIGHT: - ft_options.base.hint_style = CAIRO_HINT_STYLE_SLIGHT; -@@ -1448,7 +1912,7 @@ _cairo_ft_options_merge (cairo_ft_options_t *options, - } - - if (other->base.antialias == CAIRO_ANTIALIAS_SUBPIXEL && -- (options->base.antialias == CAIRO_ANTIALIAS_DEFAULT || -+ (options->base.antialias == CAIRO_ANTIALIAS_DEFAULT || - options->base.antialias == CAIRO_ANTIALIAS_GRAY)) { - options->base.antialias = CAIRO_ANTIALIAS_SUBPIXEL; - options->base.subpixel_order = other->base.subpixel_order; -@@ -1460,6 +1924,12 @@ _cairo_ft_options_merge (cairo_ft_options_t *options, +@@ -1490,6 +1954,12 @@ _cairo_ft_options_merge (cairo_ft_options_t *options, if (other->base.hint_style == CAIRO_HINT_STYLE_NONE) options->base.hint_style = CAIRO_HINT_STYLE_NONE; @@ -1049,7 +1027,7 @@ index 17699de..aaf8620 100644 if (options->base.antialias == CAIRO_ANTIALIAS_NONE) { if (options->base.hint_style == CAIRO_HINT_STYLE_NONE) load_flags |= FT_LOAD_NO_HINTING; -@@ -1472,7 +1942,7 @@ _cairo_ft_options_merge (cairo_ft_options_t *options, +@@ -1502,7 +1972,7 @@ _cairo_ft_options_merge (cairo_ft_options_t *options, load_flags |= FT_LOAD_NO_HINTING; break; case CAIRO_HINT_STYLE_SLIGHT: @@ -1058,23 +1036,7 @@ index 17699de..aaf8620 100644 break; case CAIRO_HINT_STYLE_MEDIUM: break; -@@ -1909,12 +2379,12 @@ _cairo_ft_scaled_glyph_init (void *abstract_font, - x2 = (metrics->vertBearingX + metrics->width + 63) & -64; - y1 = (metrics->vertBearingY) & -64; - y2 = (metrics->vertBearingY + metrics->height + 63) & -64; -- -+ - advance = ((metrics->vertAdvance + 32) & -64); -- -+ - fs_metrics.x_bearing = DOUBLE_FROM_26_6 (x1) * x_factor; - fs_metrics.y_bearing = DOUBLE_FROM_26_6 (y1) * y_factor; -- -+ - fs_metrics.width = DOUBLE_FROM_26_6 (x2 - x1) * x_factor; - fs_metrics.height = DOUBLE_FROM_26_6 (y2 - y1) * y_factor; - -@@ -2429,6 +2899,34 @@ _cairo_ft_font_options_substitute (const cairo_font_options_t *options, +@@ -2516,6 +2986,34 @@ _cairo_ft_font_options_substitute (const cairo_font_options_t *options, } } @@ -1109,19 +1071,6 @@ index 17699de..aaf8620 100644 if (options->hint_style != CAIRO_HINT_STYLE_DEFAULT) { if (FcPatternGet (pattern, FC_HINTING, 0, &v) == FcResultNoMatch) -@@ -2802,10 +3300,10 @@ cairo_bool_t - _cairo_ft_scaled_font_is_vertical (cairo_scaled_font_t *scaled_font) - { - cairo_ft_scaled_font_t *ft_scaled_font; -- -+ - if (!_cairo_scaled_font_is_ft (scaled_font)) - return FALSE; -- -+ - ft_scaled_font = (cairo_ft_scaled_font_t *) scaled_font; - if (ft_scaled_font->ft_options.load_flags & FT_LOAD_VERTICAL_LAYOUT) - return TRUE; diff --git a/src/cairo-mutex.c b/src/cairo-mutex.c index 5b6a6e1..8b50a2e 100644 --- a/src/cairo-mutex.c @@ -1136,10 +1085,10 @@ index 5b6a6e1..8b50a2e 100644 #undef CAIRO_MUTEX_DECLARE diff --git a/src/cairo-surface.c b/src/cairo-surface.c -index 4dd034e..52a271c 100644 +index f656ed5..4561117 100644 --- a/src/cairo-surface.c +++ b/src/cairo-surface.c -@@ -64,6 +64,7 @@ const cairo_surface_t name = { \ +@@ -70,6 +70,7 @@ const cairo_surface_t name = { \ FALSE, /* has_font_options */ \ { CAIRO_ANTIALIAS_DEFAULT, /* antialias */ \ CAIRO_SUBPIXEL_ORDER_DEFAULT, /* subpixel_order */ \ @@ -1148,10 +1097,10 @@ index 4dd034e..52a271c 100644 CAIRO_HINT_METRICS_DEFAULT /* hint_metrics */ \ } /* font_options */ \ diff --git a/src/cairo-types-private.h b/src/cairo-types-private.h -index 149d894..acd4f49 100644 +index a68fe50..ba608bb 100644 --- a/src/cairo-types-private.h +++ b/src/cairo-types-private.h -@@ -116,9 +116,35 @@ struct _cairo_array { +@@ -117,9 +117,35 @@ struct _cairo_array { cairo_bool_t is_snapshot; }; @@ -1188,10 +1137,10 @@ index 149d894..acd4f49 100644 cairo_hint_metrics_t hint_metrics; }; diff --git a/src/cairo-xlib-screen.c b/src/cairo-xlib-screen.c -index 3b1ae2e..ddd24f8 100644 +index e491a33..4248b64 100644 --- a/src/cairo-xlib-screen.c +++ b/src/cairo-xlib-screen.c -@@ -153,13 +153,22 @@ _cairo_xlib_init_screen_font_options (Display *dpy, +@@ -150,13 +150,22 @@ _cairo_xlib_init_screen_font_options (Display *dpy, cairo_bool_t xft_antialias; int xft_hintstyle; int xft_rgba; @@ -1214,7 +1163,7 @@ index 3b1ae2e..ddd24f8 100644 if (!get_boolean_default (dpy, "hinting", &xft_hinting)) xft_hinting = TRUE; -@@ -242,6 +251,24 @@ _cairo_xlib_init_screen_font_options (Display *dpy, +@@ -239,6 +248,24 @@ _cairo_xlib_init_screen_font_options (Display *dpy, subpixel_order = CAIRO_SUBPIXEL_ORDER_DEFAULT; } @@ -1239,7 +1188,7 @@ index 3b1ae2e..ddd24f8 100644 if (xft_antialias) { if (subpixel_order == CAIRO_SUBPIXEL_ORDER_DEFAULT) antialias = CAIRO_ANTIALIAS_GRAY; -@@ -254,6 +281,7 @@ _cairo_xlib_init_screen_font_options (Display *dpy, +@@ -251,6 +278,7 @@ _cairo_xlib_init_screen_font_options (Display *dpy, cairo_font_options_set_hint_style (&info->font_options, hint_style); cairo_font_options_set_antialias (&info->font_options, antialias); cairo_font_options_set_subpixel_order (&info->font_options, subpixel_order); @@ -1248,10 +1197,10 @@ index 3b1ae2e..ddd24f8 100644 } diff --git a/src/cairoint.h b/src/cairoint.h -index a67dff5..2c0531a 100644 +index 3cd0cb3..401f638 100644 --- a/src/cairoint.h +++ b/src/cairoint.h -@@ -1411,6 +1411,13 @@ cairo_private void +@@ -1429,6 +1429,13 @@ cairo_private void _cairo_font_options_init_copy (cairo_font_options_t *options, const cairo_font_options_t *other); |
