78 lines · 2.5 KB · Text
RawDownload
This file is part of MXE. See LICENSE.md for licensing information. Contains ad hoc patches for cross building. From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001From: Hans Petter Jansson <hpj@cl.no>Date: Sat, 5 Feb 2022 00:30:55 +0100Subject: [PATCH 1/3] Insist that ssize_t is defined  diff --git a/util/cairo-missing/cairo-missing.h b/util/cairo-missing/cairo-missing.hindex 1111111..2222222 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 #include <windows.h>  From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001From: Hans Petter Jansson <hpj@cl.no>Date: Sat, 5 Feb 2022 00:32:53 +0100Subject: [PATCH 2/3] When DllMain is not being run, initialize font face mutex  diff --git a/src/win32/cairo-win32-font.c b/src/win32/cairo-win32-font.cindex 1111111..2222222 100644--- a/src/win32/cairo-win32-font.c+++ b/src/win32/cairo-win32-font.c@@ -1679,6 +1679,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. */@@ -1694,6 +1698,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);      if (unlikely (cairo_win32_font_face_hash_table == NULL)) From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001From: Taj Morton <tajmorton@gmail.com>Date: Sun, 23 Mar 2025 19:23:59 +0000Subject: [PATCH 3/3] Include libstdc++ in private (static) link list to link with gcc. Allows C applications to link to libcairo using gcc (as opposed tog++) by explicitly linking against libstdc++. diff --git a/src/meson.build b/src/meson.buildindex 1111111..2222222 100644--- a/src/meson.build+++ b/src/meson.build@@ -264,6 +264,7 @@ libcairo_dep = declare_dependency(link_with: libcairo, pkgmod.generate(libcairo,   description: 'Multi-platform 2D graphics library',   subdirs: [meson.project_name()],+  libraries_private: '-lstdc++',  # Support static linking to cairo using gcc. )  meson.override_dependency('cairo', libcairo_dep)

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t