Skip to content

Comments

feat: add RISC-V 64-bit platform support#1496

Open
gounthar wants to merge 1 commit intosdkman:masterfrom
gounthar:feat/riscv64-platform-support
Open

feat: add RISC-V 64-bit platform support#1496
gounthar wants to merge 1 commit intosdkman:masterfrom
gounthar:feat/riscv64-platform-support

Conversation

@gounthar
Copy link

@gounthar gounthar commented Feb 6, 2026

Summary

  • Add riscv64linuxriscv64 mapping to the test platform map in UnixUtils.groovy
  • Add 4 Cucumber BDD scenarios for Java installation on RISC-V (install, default install, failed download, unsupported version)
  • Include test fixtures (tar.gz archives + hook scripts) for linuxriscv64
  • Fix the machine step definition to synchronize var/platform with the stubbed architecture, enabling correct WireMock API routing for non-host platforms

Motivation

RISC-V 64-bit (riscv64) hardware is increasingly available, but SDKMAN classifies it as "Exotic", preventing Java candidate listing/installation. While the full fix requires changes to the installer (get.sdkman.io) and backend (DISCO API), this PR prepares the CLI's test infrastructure so that:

  1. Running tests on RISC-V hardware produces the correct linuxriscv64 platform string
  2. RISC-V installation flows are verified through Cucumber scenarios
  3. The platform descriptor synchronization fix also benefits any future non-x86_64 platform additions

Fixes #1321

Test plan

  • All 179 tests pass (including 4 new RISC-V scenarios)
  • Existing x86_64 and platform-agnostic scenarios unaffected
  • ./gradlew clean test --info passes on Linux x86_64

Changes

File Change
UnixUtils.groovy Add "riscv64": "linuxriscv64" to Linux platform map
initialisation_steps.groovy Sync var/platform file when machine architecture is set
java_installation.feature Add 4 RISC-V scenarios mirroring x86_64 test coverage
jdk-8.0.{111,101}-linuxriscv64.tar.gz Test fixture archives (copies of linuxx64 fixtures)
post_hook_java_8.0.{111,101}_linuxriscv64.sh Hook scripts (copies of linuxx64 hooks)

Add riscv64 to the platform map in UnixUtils, resolving to
linuxriscv64 platform string. Include test fixtures (tar.gz archives
and hook scripts) and 4 Cucumber scenarios covering install, default
install, failed download, and unsupported version on RISC-V.

Update the machine step definition to synchronize the platform
descriptor file with the stubbed architecture, enabling correct
WireMock routing for non-host platforms.

Fixes sdkman#1321
This was referenced Feb 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Feature: RISC-V Platform Support in SDKMAN!

1 participant