question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Can't install scala-cli or cs on aarch64 architecture

See original GitHub issue

This is issue is now an umbrella issue about aarch64 support. Please see also #2614 and #2516.


I’m not sure this should be opened here but while trying to install scala-cli using coursier on an ARM64 (aarch64) host, I get:

❯ cs install scala-cli
https://repo1.maven.org/maven2/org/virtuslab/scala-cli/cli_3/maven-metadata.xml
  No new update since 2022-09-13 13:14:45
https://repo1.maven.org/maven2/com/google/code/gson/gson/maven-metadata.xml
  No new update since 2022-07-31 18:29:36
Exception in thread "main" coursier.jvm.JvmCache$JvmNotFoundInIndex: JVM graalvm:19.3 not found in index: JVM graalvm not found
	at coursier.jvm.JvmCache.$anonfun$getIfInstalled$1(JvmCache.scala:35)
	at coursier.jvm.JvmCache.$anonfun$getIfInstalled$1$adapted(JvmCache.scala:34)
	at coursier.util.Task$.$anonfun$flatMap$extension$1(Task.scala:14)
	at coursier.util.Task$.$anonfun$flatMap$extension$1$adapted(Task.scala:14)
	at coursier.util.Task$.wrap(Task.scala:82)
	at coursier.util.Task$.$anonfun$flatMap$2(Task.scala:14)
	at scala.concurrent.Future.$anonfun$flatMap$1(Future.scala:307)
	at scala.concurrent.impl.Promise.$anonfun$transformWith$1(Promise.scala:41)
	at scala.concurrent.impl.CallbackRunnable.run(Promise.scala:64)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
	at java.lang.Thread.run(Thread.java:833)
	at com.oracle.svm.core.thread.PlatformThreads.threadStartRoutine(PlatformThreads.java:704)
	at com.oracle.svm.core.posix.thread.PosixPlatformThreads.pthreadStartRoutine(PosixPlatformThreads.java:202)
❯ which java
/home/carlosedp/.cache/coursier/arc/https/github.com/graalvm/graalvm-ce-builds/releases/download/vm-22.2.0/graalvm-ce-java17-linux-aarch64-22.2.0.tar.gz/graalvm-ce-java17-22.2.0/bin/java
❯ java -version
openjdk version "17.0.4" 2022-07-19
OpenJDK Runtime Environment GraalVM CE 22.2.0 (build 17.0.4+8-jvmci-22.2-b06)
OpenJDK 64-Bit Server VM GraalVM CE 22.2.0 (build 17.0.4+8-jvmci-22.2-b06, mixed mode, sharing)

❯ uname -a
Linux corellia 5.19.0-15-generic #15-Ubuntu SMP PREEMPT_DYNAMIC Tue Aug 2 07:45:33 UTC 2022 aarch64 aarch64 aarch64 GNU/Linux

❯ cs list
amm
bloop-jvm
cs
g8
mdoc
mill
sbt
scala
scalafix
scalafmt

As seen I already have some other tools installed thru cs and GraalVM properly set.

Issue Analytics

  • State:open
  • Created a year ago
  • Reactions:1
  • Comments:19 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
lwronskicommented, Dec 9, 2022

@carlosedp @okennedy Can you try to install scala-cli in this way:

cs install scala-cli --graalvm-default-version https://github.com/graalvm/graalvm-ce-builds/releases/download/vm-22.2.0/graalvm-ce-java17-darwin-aarch64-22.2.0.tar.gz

It uses Graalvm JVM 17 for M1.

1reaction
mkurzcommented, Oct 10, 2022

I guess this needs to be re-opened. Would be nice to make this work on aarch64 on Linux (I do use Asahi Linux on my M1)

Read more comments on GitHub >

github_iconTop Results From Across the Web

Install Scala CLI
Scala CLI can be installed via apt packager tool. The Debian package can be downloaded at this address. Scala CLI can be installed...
Read more >
Single command Scala setup - Alex Archambault
This command ensures that both a JVM and the most common Scala CLI tools are installed on your machine. cs is distributed as...
Read more >
Install | The Scala Programming Language
To install Scala, it is recommended to use cs setup , the Scala installer powered by Coursier. It installs everything necessary to use...
Read more >
How to Install Scala in Linux? - GeeksforGeeks
Prerequisite: Introduction to Scala Before, we start with the process of Installing Scala on our System. We must have first-hand knowledge ...
Read more >
zsh: bad CPU type in executable - Apple Stack Exchange
When macOS tries to run an app that is not built for Apple silicon, macOS will prompt to install Rosetta 2 to automatically...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found