changeset 2613:d6edff1d892a

update package cairo
author Hans Petter Jansson <hpj@cl.no>
date Mon, 04 Jun 2012 17:56:56 +0200
parents ebe07cff1576
children 1f6e698fb89e
files index.html src/cairo-1-DllMain.patch src/cairo-1-ssize-t-defined.patch src/cairo-2-static-init.patch src/cairo.mk
diffstat 5 files changed, 49 insertions(+), 21 deletions(-) [+]
line wrap: on
line diff
--- a/index.html	Fri Jun 15 15:50:38 2012 +0200
+++ b/index.html	Mon Jun 04 17:56:56 2012 +0200
@@ -965,7 +965,7 @@
     </tr>
     <tr>
         <td id="cairo-package">cairo</td>
-        <td id="cairo-version">1.10.2</td>
+        <td id="cairo-version">1.12.2</td>
         <td id="cairo-website"><a href="http://cairographics.org/">cairo</a></td>
     </tr>
     <tr>
--- a/src/cairo-1-DllMain.patch	Fri Jun 15 15:50:38 2012 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,18 +0,0 @@
-diff -uNr cairo-1.10.2-orig/src/cairo-system.c cairo-1.10.2/src/cairo-system.c
---- cairo-1.10.2-orig/src/cairo-system.c	2010-06-18 13:47:14.000000000 +0200
-+++ cairo-1.10.2/src/cairo-system.c	2012-04-14 22:01:27.848928137 +0200
-@@ -70,12 +70,12 @@
- 
- /* declare to avoid "no previous prototype for 'DllMain'" warning */
- BOOL WINAPI
--DllMain (HINSTANCE hinstDLL,
-+cairo_DllMain (HINSTANCE hinstDLL,
-          DWORD     fdwReason,
-          LPVOID    lpvReserved);
- 
- BOOL WINAPI
--DllMain (HINSTANCE hinstDLL,
-+cairo_DllMain (HINSTANCE hinstDLL,
-          DWORD     fdwReason,
-          LPVOID    lpvReserved)
- {
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/cairo-1-ssize-t-defined.patch	Mon Jun 04 17:56:56 2012 +0200
@@ -0,0 +1,18 @@
+This file is part of MXE.
+See index.html for further information.
+
+Insist that ssize_t is defined.
+
+diff --git a/util/cairo-missing/cairo-missing.h b/util/cairo-missing/cairo-missing.h
+index 7e4f0a3..c20b869 100644
+--- a/util/cairo-missing/cairo-missing.h
++++ b/util/cairo-missing/cairo-missing.h
+@@ -37,6 +37,8 @@
+ #include <string.h>
+ #include <sys/types.h>
+ 
++#define _SSIZE_T_DEFINED 1
++
+ #ifdef _WIN32
+ #define WIN32_LEAN_AND_MEAN
+ #include <windows.h>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/cairo-2-static-init.patch	Mon Jun 04 17:56:56 2012 +0200
@@ -0,0 +1,27 @@
+This file is part of MXE.
+See index.html for further information.
+
+When DllMain is not being run, we need to initialize the font face mutex before using it.
+
+diff --git a/src/win32/cairo-win32-font.c b/src/win32/cairo-win32-font.c
+index a65d81b..31d854d 100644
+--- a/src/win32/cairo-win32-font.c
++++ b/src/win32/cairo-win32-font.c
+@@ -1912,6 +1912,8 @@ _cairo_win32_font_face_hash_table_destroy (void)
+ {
+     cairo_hash_table_t *hash_table;
+ 
++    CAIRO_MUTEX_INITIALIZE ();
++
+     /* We manually acquire the lock rather than calling
+      * _cairo_win32_font_face_hash_table_lock simply to avoid creating
+      * the table only to destroy it again. */
+@@ -1927,6 +1929,8 @@ _cairo_win32_font_face_hash_table_destroy (void)
+ static cairo_hash_table_t *
+ _cairo_win32_font_face_hash_table_lock (void)
+ {
++    CAIRO_MUTEX_INITIALIZE ();
++
+     CAIRO_MUTEX_LOCK (_cairo_win32_font_face_mutex);
+ 
+     if (unlikely (cairo_win32_font_face_hash_table == NULL))
--- a/src/cairo.mk	Fri Jun 15 15:50:38 2012 +0200
+++ b/src/cairo.mk	Mon Jun 04 17:56:56 2012 +0200
@@ -3,9 +3,9 @@
 
 PKG             := cairo
 $(PKG)_IGNORE   :=
-$(PKG)_CHECKSUM := ccce5ae03f99c505db97c286a0c9a90a926d3c6e
+$(PKG)_CHECKSUM := bc2ee50690575f16dab33af42a2e6cdc6451e3f9
 $(PKG)_SUBDIR   := cairo-$($(PKG)_VERSION)
-$(PKG)_FILE     := cairo-$($(PKG)_VERSION).tar.gz
+$(PKG)_FILE     := cairo-$($(PKG)_VERSION).tar.xz
 $(PKG)_URL      := http://cairographics.org/releases/$($(PKG)_FILE)
 $(PKG)_DEPS     := gcc zlib libpng fontconfig freetype pixman
 
@@ -44,6 +44,7 @@
         --enable-pdf \
         --enable-svg \
         --disable-pthread \
+        CFLAGS="$(CFLAGS) -DCAIRO_WIN32_STATIC_BUILD" \
         LIBS="-lmsimg32 -lgdi32 `$(TARGET)-pkg-config pixman-1 --libs`"
     $(MAKE) -C '$(1)' -j '$(JOBS)' install bin_PROGRAMS= sbin_PROGRAMS= noinst_PROGRAMS=
 endef