Skip to content

Instantly share code, notes, and snippets.

@andyvand
Created July 23, 2025 18:28
Show Gist options
  • Select an option

  • Save andyvand/0a117eabe602e8dcb569ae1f8700ef0c to your computer and use it in GitHub Desktop.

Select an option

Save andyvand/0a117eabe602e8dcb569ae1f8700ef0c to your computer and use it in GitHub Desktop.
glib-old-macos.patch
--- glib/meson.build 2023-12-06 19:03:55
+++ glib-patched/meson.build 2025-07-23 20:24:16
@@ -897,9 +897,9 @@
endif
osx_ldflags = []
-glib_have_os_x_9_or_later = false
+glib_have_os_x_9_or_later = true
glib_have_carbon = false
-glib_have_cocoa = false
+glib_have_cocoa = true
if host_system == 'darwin'
add_languages('objc', native: false, required: true)
objcc = meson.get_compiler('objc')
@@ -913,19 +913,11 @@
if glib_have_carbon
glib_conf.set('HAVE_CARBON', true)
- glib_have_os_x_9_or_later = objcc.compiles('''#include <AvailabilityMacros.h>
- #if MAC_OS_X_VERSION_MIN_REQUIRED < 1090
- #error Compiling for minimum OS X version before 10.9
- #endif''',
- name : 'OS X 9 or later')
+ glib_have_os_x_9_or_later = true
endif
# Mac OS X Cocoa support
- glib_have_cocoa = objcc.compiles('''#include <Cocoa/Cocoa.h>
- #ifdef GNUSTEP_BASE_VERSION
- #error "Detected GNUstep, not Cocoa"
- #endif''',
- name : 'Mac OS X Cocoa support')
+ glib_have_cocoa = true
if glib_have_cocoa
glib_conf.set('HAVE_COCOA', true)
@@ -2101,7 +2093,6 @@
# Try again with the fallback
if not pcre2.found()
pcre2 = dependency('libpcre2-8', version: pcre2_req, allow_fallback: true, default_options: ['default_library=static'])
- assert(pcre2.type_name() == 'internal')
# static flags are automatically enabled by the subproject if it's built
# with default_library=static
use_pcre2_static_flag = false
@@ -2169,7 +2160,6 @@
else
# using proxy-libintl fallback
libintl = dependency('intl', allow_fallback: true)
- assert(libintl.type_name() == 'internal')
libintl_deps = [libintl]
have_bind_textdomain_codeset = true # proxy-libintl supports it
endif
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment