Running IntelliJ on the M1 Mac

Andrew Boro
Feb 10, 2021

I have downloaded the M1 version of IntelliJ Idea. On the new project screen I clicked on download JDK. I was expecting it would download the right version. But no. Bad CPU type.

Cannot run program “/Users/andrewboro/Library/Java/JavaVirtualMachines/openjdk-15.0.2/Contents/Home/bin/java” (in directory “/Users/andrewboro/Library/Caches/JetBrains/IntelliJIdea2020.3/compile-server”): error=86, Bad CPU type in executable

How to fix it?

Download ZULU.

Run it again.

/Library/Java/JavaVirtualMachines/zulu-15.jdk/Contents/Home/bin/java -javaagent:/Applications/IntelliJ IDEA.app/Contents/lib/idea_rt.jar=50339:/Applications/IntelliJ IDEA.app/Contents/bin -Dfile.encoding=UTF-8 -classpath /Users/andrewboro/IdeaProjects/HelloWorld/target/classes HelloWorld
Hello, Andrew

Process finished with exit code 0

--

--