Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Artemis and Java on Mac #345

Open
OmniyaF opened this issue May 1, 2023 · 4 comments
Open

Artemis and Java on Mac #345

OmniyaF opened this issue May 1, 2023 · 4 comments

Comments

@OmniyaF
Copy link

OmniyaF commented May 1, 2023

in mac M1 I have installed Open JDK 11.0.9.1 (confirmed with Java - version) and Artemis 11.0.9.1 is not working says
"This application requires that Java 9 or later be installed on your computer." The Java path is correct.

any advice?

@martinghunt
Copy link

This hack worked for me on an M1 mac to be able to start Artemis and ACT from a terminal.

At the time I did this about a year ago, Open JDK 18 was the latest. Now it's on 20. So if you use 20 then you'll need to edit bits of the following. I keep executables in a ~/bin directory - again you'll need to edit the following if you put things elsewhere.

Get OpenJDK compiled for macOS/AArch64 from here: https://jdk.java.net/18/ . Extract into my ~/bin directory.

Download Artemis, double click on dmg, so is visible in /Volumes. Copy the whole Artemis_Tools/ dir into ~/bin.
Then put this in a script called art, fixing any paths for your system (and downloaded version of jdk):

#!/usr/bin/env bash
export PATH=$HOME/bin/jdk-18.0.1.1.jdk/Contents/Home/bin:$PATH
$HOME/bin/Artemis_Tools/Artemis.app/Contents/art “$@“

Open the app once in finder with right click -> open. Otherwise it won’t open in the terminal because is not trusted.

Now running ~/bin/art should just work. Repeat the process similarly for ACT.

@bwesen
Copy link

bwesen commented Mar 12, 2024

I just tried to download Artemis for the Mac as well and it doesn't work with the same error, "Requires Java 9". Going to java.com and downloading the latest JRE for Mac gives you a "Java 8" I think. I'm not a java guy so I have no idea why the jdks are released at number 18 etc and java with numbers 8 or 9 etc. But I just see that Artemis doesn't work with the latest Java release for Mac which is weird.

https://www.java.com/en/download/
Download Java for macOS
Recommended Version 8 Update 401 (filesize: 88.59 MB)
Release date: January 16, 2024

@martinghunt
Copy link

Just setting this up on a new Mac M3 Pro Sonoma 14.4. The same instructions as above work. This time I used the latest (at the time of writing) OpenJDK JDK 21.0.2 General-Availability Release.

So this time my script ~/bin/art looks like this:

#!/usr/bin/env bash
export PATH=$HOME/bin/jdk-21.0.2.jdk/Contents/Home/bin:$PATH
$HOME/bin/Artemis_Tools/Artemis.app/Contents/art "$@"

@AymanMkhalifa
Copy link

@OmniyaF
Did you figure this problem out please?
I have the same issue and I spent all the day trying to fix it, and still nothing changed.
hope you guide me if you still remember

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

No branches or pull requests

4 participants