mirror of
https://github.com/rbenv/ruby-build.git
synced 2025-11-19 10:22:21 +01:00
Fix compiling Ruby < 2.5 by omitting --with-ext
Using `--with-ext=+` only has the indended effect (compiling all extensions that would normally get compiled) on Ruby 2.5+. On older versions, it causes none of the default extensions to get compiled, resulting in a defunct installation.
This commit is contained in:
parent
62ec07af2a
commit
efe73b4841
7 changed files with 81 additions and 58 deletions
|
|
@ -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
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue