From aa95b1e7be5667e9ef64872db329956dcf331036 Mon Sep 17 00:00:00 2001 From: Charles Oliver Nutter Date: Tue, 5 May 2026 21:36:51 -0500 Subject: [PATCH 1/2] Check host_os rather than RUBY_PLATFORM RUBY_PLATFORM has been "java" on JRuby since the mid 2000s, so use "host_os" from RbConfig::CONFIG to compare the host platform. This fixes installs on FreeBSD and OpenBSD which need to use gmake instead of make. --- ext/prism/extconf.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/prism/extconf.rb b/ext/prism/extconf.rb index 9283d62b47..a7784092f3 100644 --- a/ext/prism/extconf.rb +++ b/ext/prism/extconf.rb @@ -50,7 +50,7 @@ def make(env, target) Dir.chdir(File.expand_path("../..", __dir__)) do system( env, - RUBY_PLATFORM.match?(/openbsd|freebsd/) ? "gmake" : "make", + RbConfig::CONFIG['host_os'].match?(/openbsd|freebsd/) ? "gmake" : "make", target, exception: true ) From e15288fe11ef3ed37c3e67b44b4f788bf71dadfb Mon Sep 17 00:00:00 2001 From: Charles Oliver Nutter Date: Tue, 5 May 2026 21:50:48 -0500 Subject: [PATCH 2/2] Use insensitive match here Co-authored-by: Jeremy Evans --- ext/prism/extconf.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/prism/extconf.rb b/ext/prism/extconf.rb index a7784092f3..fafdd701ba 100644 --- a/ext/prism/extconf.rb +++ b/ext/prism/extconf.rb @@ -50,7 +50,7 @@ def make(env, target) Dir.chdir(File.expand_path("../..", __dir__)) do system( env, - RbConfig::CONFIG['host_os'].match?(/openbsd|freebsd/) ? "gmake" : "make", + RbConfig::CONFIG['host_os'].match?(/openbsd|freebsd/i) ? "gmake" : "make", target, exception: true )