Skip to content

Commit

Permalink
Set default MAKE=make on FreeBSD
Browse files Browse the repository at this point in the history
This was set to gmake in rbenv#1381
as a workaround for https://bugs.ruby-lang.org/issues/16331

YJIT builds in Ruby 3.3 previews require the use of BSD make on these
platforms, and no supported version of MRI requires the use of gmake, so
revert this.

JRuby continues to require gmake for jruby-launcher.

Fixes Github issue rbenv#2262
  • Loading branch information
Freaky committed Oct 4, 2023
1 parent 27a5309 commit e3c3b10
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 19 deletions.
8 changes: 2 additions & 6 deletions bin/ruby-build
Original file line number Diff line number Diff line change
Expand Up @@ -1357,12 +1357,8 @@ if [ -n "$noexec" ]; then
fi

if [ -z "$MAKE" ]; then
if is_freebsd; then
# Workaround for Ruby bug 16331: https://bugs.ruby-lang.org/issues/16331
# Due to this bug, build will fail with FreeBSD's make after #1368
# The bug is already fixed in upstream but GNU make is still required
# when building older releases of Ruby. Use GNU make rather than switching
# depending of Ruby version.
if is_freebsd && echo "$1" | grep -q "^jruby-"; then
# jruby-launcher requires gmake
export MAKE="gmake"
else
export MAKE="make"
Expand Down
13 changes: 0 additions & 13 deletions test/build.bats
Original file line number Diff line number Diff line change
Expand Up @@ -404,19 +404,6 @@ OUT
assert [ -x ./here/bin/package ]
}

@test "make on FreeBSD defaults to gmake" {
cached_tarball "ruby-2.0.0"

stub_repeated uname "-s : echo FreeBSD"
MAKE=gmake stub_make_install

MAKE= install_fixture definitions/vanilla-ruby
assert_success

unstub gmake
unstub uname
}

@test "can use RUBY_CONFIGURE to apply a patch" {
cached_tarball "ruby-2.0.0"

Expand Down

0 comments on commit e3c3b10

Please sign in to comment.