Skip to content

Commit c82d25e

Browse files
committed
Build gem against Ruby 3.0
1 parent 941a100 commit c82d25e

File tree

4 files changed

+5
-2
lines changed

4 files changed

+5
-2
lines changed

.circleci/config.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -173,6 +173,7 @@ workflows:
173173
- '2.5'
174174
- '2.6'
175175
- '2.7'
176+
- '3.0'
176177

177178
- test_windows:
178179
matrix:
@@ -181,3 +182,4 @@ workflows:
181182
- '2.5'
182183
- '2.6'
183184
- '2.7'
185+
- '3.0'

Rakefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ GEM_PLATFORM_HOSTS = {
1010
'x86-mingw32' => 'i686-w64-mingw32',
1111
'x64-mingw32' => 'x86_64-w64-mingw32'
1212
}
13+
RUBY_CC_VERSION='3.0.0:2.7.0:2.6.0:2.5.0:2.4.0'.freeze
1314

1415
# Add our project specific files to clean for a rebuild
1516
CLEAN.include FileList["{ext,lib}/**/*.{so,#{RbConfig::CONFIG['DLEXT']},o}"],

tasks/native_gem.rake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,6 @@ task 'gem:windows' => ['ports:cross'] do
99

1010
# and finally build the native gem
1111
GEM_PLATFORM_HOSTS.keys.each do |plat|
12-
RakeCompilerDock.sh "bundle --local && RUBY_CC_VERSION='2.7.0:2.6.0:2.5.0:2.4.0' CFLAGS='-Wall' MAKE='make -j`nproc`' rake native:#{plat} gem", platform: plat
12+
RakeCompilerDock.sh "bundle --local && RUBY_CC_VERSION=#{RUBY_CC_VERSION} CFLAGS='-Wall' MAKE='make -j`nproc`' rake native:#{plat} gem", platform: plat
1313
end
1414
end

tasks/ports.rake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ namespace :ports do
7575
GEM_PLATFORM_HOSTS.each do |gem_platform, host|
7676
# make sure to install our bundle
7777
build = ['bundle']
78-
build << "rake ports:compile[#{host}] MAKE='make -j`nproc`'"
78+
build << "RUBY_CC_VERSION=#{RUBY_CC_VERSION} rake ports:compile[#{host}] MAKE='make -j`nproc`'"
7979
RakeCompilerDock.sh build.join(' && '), platform: gem_platform
8080
end
8181
end

0 commit comments

Comments
 (0)