From e1aada209d68f78eda20fdcf98fed1aa67afdced Mon Sep 17 00:00:00 2001 From: Jeremy Soller Date: Sun, 4 May 2025 17:58:31 -0600 Subject: [PATCH] libepoxy: fix compilation --- recipes/wip/libs/other/libepoxy/recipe.toml | 20 +++++++++++++++++++- recipes/wip/libs/other/libepoxy/redox.patch | 18 ++++++++++++++++++ 2 files changed, 37 insertions(+), 1 deletion(-) create mode 100644 recipes/wip/libs/other/libepoxy/redox.patch diff --git a/recipes/wip/libs/other/libepoxy/recipe.toml b/recipes/wip/libs/other/libepoxy/recipe.toml index f7ca74b0b..3c770bf04 100644 --- a/recipes/wip/libs/other/libepoxy/recipe.toml +++ b/recipes/wip/libs/other/libepoxy/recipe.toml @@ -1,8 +1,26 @@ -#TODO missing script for Meson, see https://github.com/anholt/libepoxy#building [source] tar = "https://download.gnome.org/sources/libepoxy/1.5/libepoxy-1.5.10.tar.xz" +blake3 = "0ccee9635115fe417cfc4bc33ffd160bf1e2852bd6c03816b4af771d59462f53" +patches = ["redox.patch"] + [build] template = "custom" dependencies = [ + "liborbital", + "libpthread-stubs", + "libx11", + "libxau", + "libxcb", + "llvm18", "mesa", + "mesa-glu", + "x11proto", + "zlib", ] +script = """ +DYNAMIC_INIT +cookbook_meson \ + -Degl=no \ + -Dglx=no \ + -Dtests=false +""" diff --git a/recipes/wip/libs/other/libepoxy/redox.patch b/recipes/wip/libs/other/libepoxy/redox.patch new file mode 100644 index 000000000..58a5f96b1 --- /dev/null +++ b/recipes/wip/libs/other/libepoxy/redox.patch @@ -0,0 +1,18 @@ +diff -ruwN libepoxy-1.5.10/src/dispatch_common.c source/src/dispatch_common.c +--- libepoxy-1.5.10/src/dispatch_common.c 2022-02-17 05:56:12.000000000 -0700 ++++ source/src/dispatch_common.c 2025-05-04 17:57:31.910921783 -0600 +@@ -264,13 +264,7 @@ + long begin_count; + }; + +-static struct api api = { +-#ifndef _WIN32 +- .mutex = PTHREAD_MUTEX_INITIALIZER, +-#else +- 0, +-#endif +-}; ++static struct api api = {0}; + + static bool library_initialized; +