1 |
commit: b0584dd2c4b2859c005901b2bfe7d7d82362effc |
2 |
Author: Jory A. Pratt <anarchy <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sun Jan 29 15:52:40 2012 +0000 |
4 |
Commit: Jory Pratt <anarchy <AT> gentoo <DOT> org> |
5 |
CommitDate: Sun Jan 29 15:52:40 2012 +0000 |
6 |
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/mozilla.git;a=commit;h=b0584dd2 |
7 |
|
8 |
Make cairo-1.11.2 snapshot avaliable for build. |
9 |
|
10 |
--- |
11 |
x11-libs/cairo/Manifest | 5 + |
12 |
x11-libs/cairo/cairo-1.11.2.ebuild | 158 ++++++++++++++++++++ |
13 |
.../cairo/files/cairo-1.10.0-buggy_gradients.patch | 17 ++ |
14 |
x11-libs/cairo/files/cairo-1.10.2-qt-surface.patch | 55 +++++++ |
15 |
x11-libs/cairo/files/cairo-1.8.8-interix.patch | 16 ++ |
16 |
5 files changed, 251 insertions(+), 0 deletions(-) |
17 |
|
18 |
diff --git a/x11-libs/cairo/Manifest b/x11-libs/cairo/Manifest |
19 |
new file mode 100644 |
20 |
index 0000000..c42341b |
21 |
--- /dev/null |
22 |
+++ b/x11-libs/cairo/Manifest |
23 |
@@ -0,0 +1,5 @@ |
24 |
+AUX cairo-1.10.0-buggy_gradients.patch 581 RMD160 077fb7a18c2840c0d637d2161ca9d244cb69608b SHA1 45f4b6a834cb9f1c153f092fba18416d257d71c7 SHA256 3b622bb250b996ea5f5adc5c899af343e0efba5c477fa0e51fdbb720a8dd1b18 |
25 |
+AUX cairo-1.10.2-qt-surface.patch 2687 RMD160 9ffc2924070a7dfa917a2b05b11de1fcca571dab SHA1 6ce6a6047d6f8420ea3044d036e7d10c6ac98c61 SHA256 fb96199ec7a4cf8527726be8d0333ed883183b56960832218eca1c9ef2e05dbd |
26 |
+AUX cairo-1.8.8-interix.patch 619 RMD160 9bb28c5a88aa1f2776d32ac7020aef4ba93872b5 SHA1 857a4d2be0118a6d2d0d80388b5963a5f768341d SHA256 505be82a1a0b7f963cb49ff85ecf1fa1389a4e43621df76b91fc1529616b2299 |
27 |
+DIST cairo-1.11.2.tar.gz 25782963 RMD160 e5dd2bc36469add524b6ac8b37a7d0127c81c4bc SHA1 40b9e1066fcd33c2aeecd800764b1aa5a0ac7bde SHA256 dcd7d0b982e1db6787a4a07ac9d99aa7db0ce22abbf59d676e211310a4059126 |
28 |
+EBUILD cairo-1.11.2.ebuild 4155 RMD160 1223cf64cf4704fef82692524145734ccd9d7a2a SHA1 7b10ed68f312f9b4f107325600ddeb4a5a94967e SHA256 68810fc558e67609f575999a032032a3765c778aad05034c0fcd9be4d62e3b84 |
29 |
|
30 |
diff --git a/x11-libs/cairo/cairo-1.11.2.ebuild b/x11-libs/cairo/cairo-1.11.2.ebuild |
31 |
new file mode 100644 |
32 |
index 0000000..725bdd7 |
33 |
--- /dev/null |
34 |
+++ b/x11-libs/cairo/cairo-1.11.2.ebuild |
35 |
@@ -0,0 +1,158 @@ |
36 |
+# Copyright 1999-2011 Gentoo Foundation |
37 |
+# Distributed under the terms of the GNU General Public License v2 |
38 |
+# $Header: /var/cvsroot/gentoo-x86/x11-libs/cairo/cairo-1.10.2-r1.ebuild,v 1.13 2011/07/13 09:05:48 mduft Exp $ |
39 |
+ |
40 |
+EAPI=3 |
41 |
+ |
42 |
+EGIT_REPO_URI="git://anongit.freedesktop.org/git/cairo" |
43 |
+[[ ${PV} == *9999 ]] && GIT_ECLASS="git" |
44 |
+ |
45 |
+inherit eutils flag-o-matic autotools ${GIT_ECLASS} |
46 |
+ |
47 |
+DESCRIPTION="A vector graphics library with cross-device output support" |
48 |
+HOMEPAGE="http://cairographics.org/" |
49 |
+[[ ${PV} == *9999 ]] || SRC_URI="http://cairographics.org/snapshots/${P}.tar.gz" |
50 |
+ |
51 |
+LICENSE="|| ( LGPL-2.1 MPL-1.1 )" |
52 |
+SLOT="0" |
53 |
+KEYWORDS="alpha amd64 arm hppa ia64 ~mips ppc ppc64 s390 sh sparc x86 ~x86-fbsd ~x86-freebsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" |
54 |
+IUSE="X aqua debug directfb doc drm gallium +glib opengl openvg qt4 static-libs +svg xcb" |
55 |
+ |
56 |
+# Test causes a circular depend on gtk+... since gtk+ needs cairo but test needs gtk+ so we need to block it |
57 |
+RESTRICT="test" |
58 |
+ |
59 |
+RDEPEND="media-libs/fontconfig |
60 |
+ media-libs/freetype:2 |
61 |
+ media-libs/libpng:0 |
62 |
+ sys-libs/zlib |
63 |
+ >=x11-libs/pixman-0.18.4 |
64 |
+ directfb? ( dev-libs/DirectFB ) |
65 |
+ glib? ( dev-libs/glib:2 ) |
66 |
+ opengl? ( virtual/opengl ) |
67 |
+ openvg? ( media-libs/mesa[gallium] ) |
68 |
+ qt4? ( >=x11-libs/qt-gui-4.4:4 ) |
69 |
+ svg? ( dev-libs/libxml2 ) |
70 |
+ X? ( |
71 |
+ >=x11-libs/libXrender-0.6 |
72 |
+ x11-libs/libXext |
73 |
+ x11-libs/libX11 |
74 |
+ x11-libs/libXft |
75 |
+ drm? ( |
76 |
+ >=sys-fs/udev-136 |
77 |
+ gallium? ( media-libs/mesa[gallium] ) |
78 |
+ ) |
79 |
+ ) |
80 |
+ xcb? ( |
81 |
+ x11-libs/libxcb |
82 |
+ x11-libs/xcb-util |
83 |
+ )" |
84 |
+DEPEND="${RDEPEND} |
85 |
+ dev-util/pkgconfig |
86 |
+ >=sys-devel/libtool-2 |
87 |
+ doc? ( |
88 |
+ >=dev-util/gtk-doc-1.6 |
89 |
+ ~app-text/docbook-xml-dtd-4.2 |
90 |
+ ) |
91 |
+ X? ( |
92 |
+ x11-proto/renderproto |
93 |
+ drm? ( |
94 |
+ x11-proto/xproto |
95 |
+ >=x11-proto/xextproto-7.1 |
96 |
+ ) |
97 |
+ )" |
98 |
+ |
99 |
+src_prepare() { |
100 |
+ epatch "${FILESDIR}"/${PN}-1.8.8-interix.patch |
101 |
+ epatch "${FILESDIR}"/${PN}-1.10.0-buggy_gradients.patch |
102 |
+ epatch "${FILESDIR}"/${PN}-1.10.2-qt-surface.patch |
103 |
+ |
104 |
+ # Slightly messed build system YAY |
105 |
+ if [[ ${PV} == *9999* ]]; then |
106 |
+ touch boilerplate/Makefile.am.features |
107 |
+ touch src/Makefile.am.features |
108 |
+ touch ChangeLog |
109 |
+ fi |
110 |
+ |
111 |
+ # We need to run elibtoolize to ensure correct so versioning on FreeBSD |
112 |
+ # upgraded to an eautoreconf for the above interix patch. |
113 |
+ eautoreconf |
114 |
+} |
115 |
+ |
116 |
+src_configure() { |
117 |
+ local myopts |
118 |
+ |
119 |
+ # SuperH doesn't have native atomics yet |
120 |
+ use sh && myopts+=" --disable-atomic" |
121 |
+ |
122 |
+ [[ ${CHOST} == *-interix* ]] && append-flags -D_REENTRANT |
123 |
+ |
124 |
+ # tracing fails to compile, because Solaris' libelf doesn't do large files |
125 |
+ [[ ${CHOST} == *-solaris* ]] && myopts+=" --disable-trace" |
126 |
+ |
127 |
+ # 128-bits long arithemetic functions are missing |
128 |
+ [[ ${CHOST} == powerpc*-*-darwin* ]] && filter-flags -mcpu=* |
129 |
+ |
130 |
+ #gets rid of fbmmx.c inlining warnings |
131 |
+ append-flags -finline-limit=1200 |
132 |
+ |
133 |
+ if use X; then |
134 |
+ myopts+=" |
135 |
+ --enable-tee=yes |
136 |
+ $(use_enable drm) |
137 |
+ " |
138 |
+ |
139 |
+ if use drm; then |
140 |
+ myopts+=" |
141 |
+ $(use_enable gallium) |
142 |
+ $(use_enable xcb xcb-drm) |
143 |
+ " |
144 |
+ else |
145 |
+ use gallium && ewarn "Gallium use requires drm use enabled. So disabling for now." |
146 |
+ myopts+=" |
147 |
+ --disable-gallium |
148 |
+ --disable-xcb-drm |
149 |
+ " |
150 |
+ fi |
151 |
+ else |
152 |
+ use drm && ewarn "drm use requires X use enabled. So disabling for now." |
153 |
+ myopts+=" |
154 |
+ --disable-drm |
155 |
+ --disable-gallium |
156 |
+ --disable-xcb-drm |
157 |
+ " |
158 |
+ fi |
159 |
+ |
160 |
+ # --disable-xcb-lib: |
161 |
+ # do not override good xlib backed by hardforcing rendering over xcb |
162 |
+ econf \ |
163 |
+ --disable-dependency-tracking \ |
164 |
+ $(use_with X x) \ |
165 |
+ $(use_enable X xlib) \ |
166 |
+ $(use_enable X xlib-xrender) \ |
167 |
+ $(use_enable aqua quartz) \ |
168 |
+ $(use_enable aqua quartz-image) \ |
169 |
+ $(use_enable debug test-surfaces) \ |
170 |
+ $(use_enable directfb) \ |
171 |
+ $(use_enable glib gobject) \ |
172 |
+ $(use_enable doc gtk-doc) \ |
173 |
+ $(use_enable openvg vg) \ |
174 |
+ $(use_enable opengl gl) \ |
175 |
+ $(use_enable qt4 qt) \ |
176 |
+ $(use_enable static-libs static) \ |
177 |
+ $(use_enable svg) \ |
178 |
+ $(use_enable xcb) \ |
179 |
+ $(use_enable xcb xcb-shm) \ |
180 |
+ --enable-ft \ |
181 |
+ --enable-pdf \ |
182 |
+ --enable-png \ |
183 |
+ --enable-ps \ |
184 |
+ --disable-xlib-xcb \ |
185 |
+ ${myopts} |
186 |
+} |
187 |
+ |
188 |
+src_install() { |
189 |
+ # parallel make install fails |
190 |
+ emake -j1 DESTDIR="${D}" install || die |
191 |
+ find "${ED}" -name '*.la' -exec rm -f {} + |
192 |
+ dodoc AUTHORS ChangeLog NEWS README || die |
193 |
+} |
194 |
|
195 |
diff --git a/x11-libs/cairo/files/cairo-1.10.0-buggy_gradients.patch b/x11-libs/cairo/files/cairo-1.10.0-buggy_gradients.patch |
196 |
new file mode 100644 |
197 |
index 0000000..a58c2f8 |
198 |
--- /dev/null |
199 |
+++ b/x11-libs/cairo/files/cairo-1.10.0-buggy_gradients.patch |
200 |
@@ -0,0 +1,17 @@ |
201 |
+http://repos.archlinux.org/wsvn/packages/cairo/trunk/cairo-1.10.0-buggy_gradients.patch |
202 |
+http://bugs.gentoo.org/336696 |
203 |
+ |
204 |
+--- src/cairo-xlib-display.c |
205 |
++++ src/cairo-xlib-display.c |
206 |
+@@ -353,11 +353,7 @@ |
207 |
+ /* Prior to Render 0.10, there is no protocol support for gradients and |
208 |
+ * we call function stubs instead, which would silently consume the drawing. |
209 |
+ */ |
210 |
+-#if RENDER_MAJOR == 0 && RENDER_MINOR < 10 |
211 |
+ display->buggy_gradients = TRUE; |
212 |
+-#else |
213 |
+- display->buggy_gradients = FALSE; |
214 |
+-#endif |
215 |
+ display->buggy_pad_reflect = FALSE; |
216 |
+ display->buggy_repeat = FALSE; |
217 |
+ |
218 |
|
219 |
diff --git a/x11-libs/cairo/files/cairo-1.10.2-qt-surface.patch b/x11-libs/cairo/files/cairo-1.10.2-qt-surface.patch |
220 |
new file mode 100644 |
221 |
index 0000000..cf0b57a |
222 |
--- /dev/null |
223 |
+++ b/x11-libs/cairo/files/cairo-1.10.2-qt-surface.patch |
224 |
@@ -0,0 +1,55 @@ |
225 |
+diff -ruN cairo-1.10.2-0-vanilla/src/cairo-qt-surface.cpp cairo-1.10.2/src/cairo-qt-surface.cpp |
226 |
+--- cairo-1.10.2-0-vanilla/src/cairo-qt-surface.cpp 2010-12-25 15:21:34.000000000 +0100 |
227 |
++++ cairo-1.10.2/src/cairo-qt-surface.cpp 2011-12-20 22:59:30.000000000 +0100 |
228 |
+@@ -61,7 +61,9 @@ |
229 |
+ #include <QtGui/QX11Info> |
230 |
+ #include <QtCore/QVarLengthArray> |
231 |
+ |
232 |
+-#if (QT_VERSION >= QT_VERSION_CHECK(4, 7, 0)) || defined(QT_GLYPHS_API_BACKPORT) |
233 |
++#if (QT_VERSION >= QT_VERSION_CHECK(4, 8, 0)) |
234 |
++#include <QtGui/QGlyphRun> |
235 |
++#elif (QT_VERSION >= QT_VERSION_CHECK(4, 7, 0)) || defined(QT_GLYPHS_API_BACKPORT) |
236 |
+ extern void qt_draw_glyphs(QPainter *, const quint32 *glyphs, const QPointF *positions, int count); |
237 |
+ #endif |
238 |
+ |
239 |
+@@ -1370,7 +1372,39 @@ |
240 |
+ cairo_clip_t *clip, |
241 |
+ int *remaining_glyphs) |
242 |
+ { |
243 |
+-#if (QT_VERSION >= QT_VERSION_CHECK(4, 7, 0)) || defined(QT_GLYPHS_API_BACKPORT) |
244 |
++#if (QT_VERSION >= QT_VERSION_CHECK(4, 8, 0)) && !defined(QT_NO_RAWFONT) |
245 |
++ cairo_qt_surface_t *qs = (cairo_qt_surface_t *) abstract_surface; |
246 |
++ |
247 |
++ // pick out the colour to use from the cairo source |
248 |
++ cairo_solid_pattern_t *solid = (cairo_solid_pattern_t*) source; |
249 |
++ // documentation says you have to freeze the cache, but I don't believe it |
250 |
++ _cairo_scaled_font_freeze_cache(scaled_font); |
251 |
++ |
252 |
++ QColor tempColour(solid->color.red * 255, solid->color.green * 255, solid->color.blue * 255); |
253 |
++ QVector<QPointF> positions(num_glyphs); |
254 |
++ QVector<unsigned int> glyphss(num_glyphs); |
255 |
++ FT_Face face = cairo_ft_scaled_font_lock_face (scaled_font); |
256 |
++ const FT_Size_Metrics& ftMetrics = face->size->metrics; |
257 |
++ QFont font(face->family_name); |
258 |
++ font.setStyleStrategy(QFont::NoFontMerging); |
259 |
++ font.setBold(face->style_flags & FT_STYLE_FLAG_BOLD); |
260 |
++ font.setItalic(face->style_flags & FT_STYLE_FLAG_ITALIC); |
261 |
++ font.setKerning(face->face_flags & FT_FACE_FLAG_KERNING); |
262 |
++ font.setPixelSize(ftMetrics.y_ppem); |
263 |
++ cairo_ft_scaled_font_unlock_face(scaled_font); |
264 |
++ qs->p->setFont(font); |
265 |
++ qs->p->setPen(tempColour); |
266 |
++ for (int currentGlyph = 0; currentGlyph < num_glyphs; currentGlyph++) { |
267 |
++ positions.append(QPointF(glyphs[currentGlyph].x, glyphs[currentGlyph].y)); |
268 |
++ glyphss.append(glyphs[currentGlyph].index); |
269 |
++ } |
270 |
++ QGlyphRun qglyphs; |
271 |
++ qglyphs.setGlyphIndexes(glyphss); |
272 |
++ qglyphs.setPositions(positions); |
273 |
++ qs->p->drawGlyphRun(QPointF(), qglyphs); |
274 |
++ _cairo_scaled_font_thaw_cache(scaled_font); |
275 |
++ return CAIRO_INT_STATUS_SUCCESS; |
276 |
++#elif (QT_VERSION >= QT_VERSION_CHECK(4, 7, 0)) || defined(QT_GLYPHS_API_BACKPORT) |
277 |
+ cairo_qt_surface_t *qs = (cairo_qt_surface_t *) abstract_surface; |
278 |
+ |
279 |
+ // pick out the colour to use from the cairo source |
280 |
|
281 |
diff --git a/x11-libs/cairo/files/cairo-1.8.8-interix.patch b/x11-libs/cairo/files/cairo-1.8.8-interix.patch |
282 |
new file mode 100644 |
283 |
index 0000000..dc20714 |
284 |
--- /dev/null |
285 |
+++ b/x11-libs/cairo/files/cairo-1.8.8-interix.patch |
286 |
@@ -0,0 +1,16 @@ |
287 |
+diff -ru cairo-1.8.8.orig/build/configure.ac.tools cairo-1.8.8/build/configure.ac.tools |
288 |
+--- cairo-1.8.8.orig/build/configure.ac.tools 2009-09-30 13:36:42 +0200 |
289 |
++++ cairo-1.8.8/build/configure.ac.tools 2009-09-30 13:50:50 +0200 |
290 |
+@@ -21,5 +21,12 @@ |
291 |
+ *) PKGCONFIG_REQUIRES="Requires.private"; ;; |
292 |
+ esac |
293 |
+ |
294 |
++dnl hmm... on interix, things go really bad with Requires.private, since libpng12 |
295 |
++dnl is missing on the final link commands, so gtk+'s configure checks for cairo |
296 |
++dnl fail miserably with unresolved symbols to it. |
297 |
++case "$host_os" in |
298 |
++interix*) PKGCONFIG_REQUIRES="Requires" ;; |
299 |
++esac |
300 |
++ |
301 |
+ AC_SUBST(PKGCONFIG_REQUIRES) |
302 |
+ |