From 14deac58d7190ceb4a1e2c0f07bd965409745ec4 Mon Sep 17 00:00:00 2001 From: alex Date: Thu, 14 Oct 2021 21:47:38 +1300 Subject: [PATCH 1/3] Issue #61. Added riscv64 support Signed-off-by: alex --- README.md | 1 + src/main/java/kr/motd/maven/os/Detector.java | 3 +++ 2 files changed, 4 insertions(+) diff --git a/README.md b/README.md index 2ce5e44..51a8efb 100644 --- a/README.md +++ b/README.md @@ -45,6 +45,7 @@ * `s390_32` - if the value is `s390` * `s390_64` if the value is `s390x` * `riscv` if the value is `riscv` +* `riscv64` if the value is `riscv64` * `e2k` if the value is `e2k` Note: The bitness part of this property relies on the bitness of the JVM binary, e.g. You'll get the property that ends with `_32` if you run a 32-bit JVM on a 64-bit OS. diff --git a/src/main/java/kr/motd/maven/os/Detector.java b/src/main/java/kr/motd/maven/os/Detector.java index 56555c1..7976961 100644 --- a/src/main/java/kr/motd/maven/os/Detector.java +++ b/src/main/java/kr/motd/maven/os/Detector.java @@ -248,6 +248,9 @@ private static String normalizeArch(String value) { if ("riscv".equals(value)) { return "riscv"; } + if ("riscv64".equals(value)) { + return "riscv64"; + } if ("e2k".equals(value)) { return "e2k"; } From 6680c5783f2430408525a57e4b605d87c290a0c9 Mon Sep 17 00:00:00 2001 From: Trustin Lee Date: Mon, 7 Nov 2022 20:21:08 +0900 Subject: [PATCH 2/3] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 51a8efb..e13be98 100644 --- a/README.md +++ b/README.md @@ -44,7 +44,7 @@ * `ppcle_64` - if the value is `ppc64le` * `s390_32` - if the value is `s390` * `s390_64` if the value is `s390x` -* `riscv` if the value is `riscv` +* `riscv` if the value is `riscv` or `riscv32` * `riscv64` if the value is `riscv64` * `e2k` if the value is `e2k` From 5d2a75039a85ba4714eb239ff6848b0aabf4955b Mon Sep 17 00:00:00 2001 From: Trustin Lee Date: Mon, 7 Nov 2022 20:23:23 +0900 Subject: [PATCH 3/3] Update Detector.java --- src/main/java/kr/motd/maven/os/Detector.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/kr/motd/maven/os/Detector.java b/src/main/java/kr/motd/maven/os/Detector.java index 7976961..f170b9a 100644 --- a/src/main/java/kr/motd/maven/os/Detector.java +++ b/src/main/java/kr/motd/maven/os/Detector.java @@ -245,7 +245,7 @@ private static String normalizeArch(String value) { if ("s390x".equals(value)) { return "s390_64"; } - if ("riscv".equals(value)) { + if (value.matches("^(riscv|riscv32)$")) { return "riscv"; } if ("riscv64".equals(value)) {