diff options
author | Tobias Gruetzmacher <tobias-git@23.gs> | 2014-08-04 22:13:41 (GMT) |
---|---|---|
committer | Tobias Gruetzmacher <tobias-git@23.gs> | 2014-10-12 16:07:34 (GMT) |
commit | 44b2d8c6946dc538b7a9dab9c7fca26036196f8a (patch) | |
tree | 47d6ced38aad15518fe78720026ef57dbe0469c0 /src/cairo-2-static-init.patch | |
parent | adbcd704c3deab6e897b6b7e3703f36b6736995d (diff) | |
download | mxe-44b2d8c6946dc538b7a9dab9c7fca26036196f8a.zip mxe-44b2d8c6946dc538b7a9dab9c7fca26036196f8a.tar.gz mxe-44b2d8c6946dc538b7a9dab9c7fca26036196f8a.tar.bz2 |
cairo: Make patch useful in static and shared builds.
Diffstat (limited to 'src/cairo-2-static-init.patch')
-rw-r--r-- | src/cairo-2-static-init.patch | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/cairo-2-static-init.patch b/src/cairo-2-static-init.patch index 16d74c3..515a524 100644 --- a/src/cairo-2-static-init.patch +++ b/src/cairo-2-static-init.patch @@ -4,23 +4,27 @@ 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 +index a65d81b..d6950a1 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) +@@ -1912,6 +1912,10 @@ _cairo_win32_font_face_hash_table_destroy (void) { cairo_hash_table_t *hash_table; ++#ifdef CAIRO_WIN32_STATIC_BUILD + CAIRO_MUTEX_INITIALIZE (); ++#endif + /* 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) +@@ -1927,6 +1931,10 @@ _cairo_win32_font_face_hash_table_destroy (void) static cairo_hash_table_t * _cairo_win32_font_face_hash_table_lock (void) { ++#ifdef CAIRO_WIN32_STATIC_BUILD + CAIRO_MUTEX_INITIALIZE (); ++#endif + CAIRO_MUTEX_LOCK (_cairo_win32_font_face_mutex); |