summaryrefslogtreecommitdiffstats
path: root/xulrunner-2.0-system-cairo.patch
diff options
context:
space:
mode:
authorRemi Collet <fedora@famillecollet.com>2011-01-22 17:32:34 +0100
committerRemi Collet <fedora@famillecollet.com>2011-01-22 17:32:34 +0100
commit216a445846c995e88694a2ba65974d48bc3b92b0 (patch)
tree56aeaa941e64f84538389b704a586587c8a57fd2 /xulrunner-2.0-system-cairo.patch
parent0ecf8798df88632adb2c04e41e1bbe76c1e1c4d8 (diff)
Firefox 4.0b10 build1 candidate
Diffstat (limited to 'xulrunner-2.0-system-cairo.patch')
-rw-r--r--xulrunner-2.0-system-cairo.patch107
1 files changed, 107 insertions, 0 deletions
diff --git a/xulrunner-2.0-system-cairo.patch b/xulrunner-2.0-system-cairo.patch
new file mode 100644
index 0000000..20f236f
--- /dev/null
+++ b/xulrunner-2.0-system-cairo.patch
@@ -0,0 +1,107 @@
+https://bugzilla.mozilla.org/show_bug.cgi?id=623797
+
+work around new features that are not avaliable in system-cairo on linux
+(romaxa's patch with modification for return failure with <gcc-4.5)
+
+diff --git a/config/system-headers b/config/system-headers
+--- a/config/system-headers
++++ b/config/system-headers
+@@ -81,16 +81,17 @@ pixman.h
+ cairo.h
+ cairo-atsui.h
+ cairo-beos.h
+ cairo-ft.h
+ cairo-glitz.h
+ cairo-os2.h
+ cairo-pdf.h
+ cairo-ps.h
++cairo-tee.h
+ cairo-quartz.h
+ cairo-win32.h
+ cairo-xlib.h
+ cairo-xlib-xrender.h
+ cairo-directfb.h
+ cairo-qpainter.h
+ #endif
+ dfiff.h
+diff --git a/gfx/thebes/gfxASurface.cpp b/gfx/thebes/gfxASurface.cpp
+--- a/gfx/thebes/gfxASurface.cpp
++++ b/gfx/thebes/gfxASurface.cpp
+@@ -216,19 +216,21 @@ gfxASurface::Init(cairo_surface_t* surfa
+
+ mSurface = surface;
+ mSurfaceValid = PR_TRUE;
+
+ if (existingSurface) {
+ mFloatingRefs = 0;
+ } else {
+ mFloatingRefs = 1;
++#ifdef MOZ_TREE_CAIRO
+ if (cairo_surface_get_content(surface) != CAIRO_CONTENT_COLOR) {
+ cairo_surface_set_subpixel_antialiasing(surface, CAIRO_SUBPIXEL_ANTIALIASING_DISABLED);
+ }
++#endif
+ }
+ }
+
+ gfxASurface::gfxSurfaceType
+ gfxASurface::GetType() const
+ {
+ if (!mSurfaceValid)
+ return (gfxSurfaceType)-1;
+@@ -432,26 +434,32 @@ gfxASurface::FormatFromContent(gfxASurfa
+ }
+ }
+
+ void
+ gfxASurface::SetSubpixelAntialiasingEnabled(PRBool aEnabled)
+ {
+ if (!mSurfaceValid)
+ return;
++#ifdef MOZ_TREE_CAIRO
+ cairo_surface_set_subpixel_antialiasing(mSurface,
+ aEnabled ? CAIRO_SUBPIXEL_ANTIALIASING_ENABLED : CAIRO_SUBPIXEL_ANTIALIASING_DISABLED);
++#endif
+ }
+
+ PRBool
+ gfxASurface::GetSubpixelAntialiasingEnabled()
+ {
+ if (!mSurfaceValid)
+ return PR_FALSE;
++#ifdef MOZ_TREE_CAIRO
+ return cairo_surface_get_subpixel_antialiasing(mSurface) == CAIRO_SUBPIXEL_ANTIALIASING_ENABLED;
++#else
++ return PR_TRUE;
++#endif
+ }
+
+ PRInt32
+ gfxASurface::BytePerPixelFromFormat(gfxImageFormat format)
+ {
+ switch (format) {
+ case ImageFormatARGB32:
+ case ImageFormatRGB24:
+diff --git a/js/src/config/system-headers b/js/src/config/system-headers
+--- a/js/src/config/system-headers
++++ b/js/src/config/system-headers
+@@ -82,16 +82,17 @@ cairo.h
+ cairo-atsui.h
+ cairo-beos.h
+ cairo-ft.h
+ cairo-glitz.h
+ cairo-os2.h
+ cairo-pdf.h
+ cairo-ps.h
+ cairo-quartz.h
++cairo-tee.h
+ cairo-win32.h
+ cairo-xlib.h
+ cairo-xlib-xrender.h
+ cairo-directfb.h
+ cairo-qpainter.h
+ #endif
+ dfiff.h
+ exception
+
+