@@ -63,7 +63,7 @@ export async function install(platform, engine, version) {
6363 // install msys2 tools for all Ruby versions, only install mingw or ucrt for Rubies >= 2.4
6464
6565 if ( ! [ 'windows-2019' , 'windows-2016' ] . includes ( virtualEnv ) ) {
66- await installMSY2Tools ( )
66+ await installMSYS2Tools ( )
6767 }
6868
6969 if ( ( ( winMSYS2Type === 'ucrt64' ) || ! [ 'windows-2019' , 'windows-2016' ] . includes ( virtualEnv ) ) &&
@@ -95,7 +95,7 @@ async function installGCCTools(type) {
9595
9696// Actions windows-2022 image does not contain any MSYS2 build tools. Install tools for it.
9797// A subset of the MSYS2 base-devel group
98- async function installMSY2Tools ( ) {
98+ async function installMSYS2Tools ( ) {
9999 const downloadPath = await common . measure ( `Downloading msys2 build tools` , async ( ) => {
100100 let url = `https://github.com/MSP-Greg/setup-msys2-gcc/releases/download/msys2-gcc-pkgs/msys2.7z`
101101 console . log ( url )
@@ -111,6 +111,13 @@ async function installMSY2Tools() {
111111 exec . exec ( '7z' , [ 'x' , downloadPath , '-aoa' , '-bd' , `-o${ msys2BasePath } ` ] , { silent : true } ) )
112112}
113113
114+ // Windows JRuby can install gems that require compile tools, only needed for
115+ // windows-2022 image
116+ export async function installJRubyTools ( ) {
117+ await installMSYS2Tools ( )
118+ await installGCCTools ( 'mingw64' )
119+ }
120+
114121async function downloadAndExtract ( engine , version , url , base , rubyPrefix ) {
115122 const parentDir = path . dirname ( rubyPrefix )
116123
0 commit comments