Skip to content

Commit

Permalink
Merge pull request #2316 from rbenv/fix-ruby-2.4
Browse files Browse the repository at this point in the history
Fix compiling Ruby < 2.5 by omitting `--with-ext`
  • Loading branch information
mislav authored Nov 24, 2023
2 parents 62ec07a + efe73b4 commit d12f6e5
Show file tree
Hide file tree
Showing 7 changed files with 81 additions and 58 deletions.
7 changes: 5 additions & 2 deletions bin/ruby-build
Original file line number Diff line number Diff line change
Expand Up @@ -674,8 +674,11 @@ build_package_standard_build() {
fi
fi
if [[ "$RUBY_CONFIGURE_OPTS ${RUBY_CONFIGURE_OPTS_ARRAY[*]}" != *--with-ext* &&
"$RUBY_CONFIGURE_OPTS ${RUBY_CONFIGURE_OPTS_ARRAY[*]}" != *--without-ext* ]]; then
# Fail the `make` step if any of these extensions were not compiled.
"$RUBY_CONFIGURE_OPTS ${RUBY_CONFIGURE_OPTS_ARRAY[*]}" != *--without-ext* &&
"$(normalize_semver "${package_name#ruby-}")" -ge 200500 ]]; then
# For Ruby 2.5+, fail the `make` step if any of these extensions were not compiled.
# Otherwise, the build would have succeeded, but Ruby would be useless at runtime.
# https://github.com/ruby/ruby/commit/b58a30e1c14e971adba4096104274d5d692492e9
package_option ruby configure --with-ext=openssl,psych,+
fi
fi
Expand Down
Loading

0 comments on commit d12f6e5

Please sign in to comment.