From b4ed5b7dfe9ca01ef48922d1b2c154767b7e4e86 Mon Sep 17 00:00:00 2001 From: Takashi Kokubun Date: Tue, 16 Jan 2024 15:54:17 -0800 Subject: [PATCH] Bump the required BASERUBY version to 2.7 (#9566) [[Misc #16671]](https://bugs.ruby-lang.org/issues/16671) --- .github/workflows/baseruby.yml | 4 +--- .github/workflows/mingw.yml | 4 ++-- .github/workflows/windows.yml | 5 +++++ configure.ac | 4 ++-- 4 files changed, 10 insertions(+), 7 deletions(-) diff --git a/.github/workflows/baseruby.yml b/.github/workflows/baseruby.yml index 5ead3fa03f4883..674b42b8b70608 100644 --- a/.github/workflows/baseruby.yml +++ b/.github/workflows/baseruby.yml @@ -50,9 +50,7 @@ jobs: strategy: matrix: ruby: - - ruby-2.5 -# - ruby-2.6 -# - ruby-2.7 + - ruby-2.7 - ruby-3.0 - ruby-3.1 - ruby-3.2 diff --git a/.github/workflows/mingw.yml b/.github/workflows/mingw.yml index c7a550c7c79251..5ed71716f9fc04 100644 --- a/.github/workflows/mingw.yml +++ b/.github/workflows/mingw.yml @@ -59,7 +59,7 @@ jobs: include: # To mitigate flakiness of MinGW CI, we test only one runtime that newer MSYS2 uses. - msystem: 'UCRT64' - base_ruby: head + baseruby: '2.7' test_task: 'check' test-all-opts: '--name=!/TestObjSpace#test_reachable_objects_during_iteration/' fail-fast: false @@ -76,7 +76,7 @@ jobs: - name: Set up Ruby & MSYS2 uses: ruby/setup-ruby@360dc864d5da99d54fcb8e9148c14a84b90d3e88 # v1.165.1 with: - ruby-version: ${{ matrix.base_ruby }} + ruby-version: ${{ matrix.baseruby }} - name: where check run: | diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index a31545fe5a37a5..c8d61be7630a5d 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -133,6 +133,7 @@ jobs: builddir: build - name: setup env + # Available Ruby versions: https://github.com/actions/runner-images/blob/main/images/windows/Windows2019-Readme.md#ruby # %TEMP% is inconsistent with %TMP% and test-all expects they are consistent. # https://github.com/actions/virtual-environments/issues/712#issuecomment-613004302 run: | @@ -146,10 +147,14 @@ jobs: set TEMP=%USERPROFILE%\AppData\Local\Temp set MAKEFLAGS=l set /a TEST_JOBS=(15 * %NUMBER_OF_PROCESSORS% / 10) > nul + set PATH=C:\hostedtoolcache\windows\Ruby\2.7.8\x64\bin;%PATH% set | C:\msys64\usr\bin\sort > new.env C:\msys64\usr\bin\comm -13 old.env new.env >> %GITHUB_ENV% del *.env + - name: baseruby version + run: ruby -v + - name: compiler version run: cl diff --git a/configure.ac b/configure.ac index 277c8747c0001e..54d0b5b47428a4 100644 --- a/configure.ac +++ b/configure.ac @@ -75,8 +75,8 @@ AC_ARG_WITH(baseruby, [ AC_PATH_PROG([BASERUBY], [ruby], [false]) ]) -# BASERUBY must be >= 2.5.0. Note that `"2.5.0" > "2.5"` is true. -AS_IF([test "$HAVE_BASERUBY" != no -a "`RUBYOPT=- $BASERUBY --disable=gems -e 'print 42 if RUBY_VERSION > "2.5"' 2>/dev/null`" = 42], [ +# BASERUBY must be >= 2.7.0. Note that `"2.7.0" > "2.7"` is true. +AS_IF([test "$HAVE_BASERUBY" != no -a "`RUBYOPT=- $BASERUBY --disable=gems -e 'print 42 if RUBY_VERSION > "2.7"' 2>/dev/null`" = 42], [ AS_CASE(["$build_os"], [mingw*], [ # Can MSys shell run a command with a drive letter? RUBYOPT=- `cygpath -ma "$BASERUBY"` --disable=gems -e exit 2>/dev/null || HAVE_BASERUBY=no