Skip to content

[brew in non-default location][macos_arm64] unable to compile glib #4463

Closed Answered by ycsin
ycsin asked this question in Everyday usage
Discussion options

You must be logged in to vote

I was tipped by a colleague of mine to disable the test (so that it doesn't fail) and recompile, here is the diff:

diff --git a/Formula/glib.rb b/Formula/glib.rb
index 8234133c21f..c5c873fb06e 100644
--- a/Formula/glib.rb
+++ b/Formula/glib.rb
@@ -47,6 +47,8 @@ class Glib < Formula
   end
 
   def install
+    inreplace "glib/tests/meson.build", "if not meson.is_cross_build() and host_system != 'windows'", "if false"
+    inreplace "gio/meson.build", "if build_tests", "if false"
     inreplace %w[gio/xdgmime/xdgmime.c glib/gutils.c], "@@HOMEBREW_PREFIX@@", HOMEBREW_PREFIX
     # Avoid the sandbox violation when an empty directory is created outside of the formula prefix.
     inreplace "g…

Replies: 2 comments 4 replies

Comment options

You must be logged in to vote
4 replies
@ycsin
Comment options

@ericshenshs
Comment options

@ycsin
Comment options

Answer selected by ycsin
@ericshenshs
Comment options

Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
4 participants