Skip to content

Commit efbf473

Browse files
ntkmeeregon
authored andcommitted
Add JRuby for Windows on Arm
1 parent bd28d36 commit efbf473

File tree

3 files changed

+12
-5
lines changed

3 files changed

+12
-5
lines changed

.github/workflows/test.yml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -75,9 +75,6 @@ jobs:
7575
- { os: windows-11-arm, ruby: '3.1' }
7676
- { os: windows-11-arm, ruby: '3.2' }
7777
- { os: windows-11-arm, ruby: '3.3' }
78-
# https://github.com/ruby/jruby-dev-builder/pull/14#issuecomment-2829841247
79-
- { os: windows-11-arm, ruby: jruby }
80-
- { os: windows-11-arm, ruby: jruby-head }
8178
# RubyInstaller has no 64-bit builds of 1.9 on Windows
8279
- { os: windows-2022, ruby: '1.9' }
8380
- { os: windows-2025, ruby: '1.9' }

common.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -395,10 +395,15 @@ export async function setupJavaHome(rubyPrefix) {
395395
console.log("JRuby failed to start, try Java 21 envs")
396396

397397
let arch = os.arch()
398-
if (arch === "x64" || os.platform() !== "darwin") {
398+
if (arch === "arm64" && os.platform() === "win32") {
399+
arch = "AARCH64"
400+
} else if (arch === "x64" || os.platform() !== "darwin") {
399401
arch = "X64"
400402
}
401403

404+
// JAVA_HOME_21_AARCH64 - https://github.com/actions/partner-runner-images/blob/main/images/arm-windows-11-image.md#java
405+
// JAVA_HOME_21_arm64 - https://github.com/actions/runner-images/blob/main/images/macos/macos-15-arm64-Readme.md#java
406+
// JAVA_HOME_21_X64 - https://github.com/actions/runner-images/blob/main/images/ubuntu/Ubuntu2404-Readme.md#java
402407
let newHomeVar = `JAVA_HOME_21_${arch}`
403408
let newHome = process.env[newHomeVar]
404409

dist/index.js

Lines changed: 6 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)