I installed jEdit on my new mac (Intel processor 11.3.1 Big Sur) but it gives me the message
"This application requires that java 11 or later be installed on your computer."
So I installed java with brew install java
and followed the instructions to symlink it, and add it to my .zsh PATH. All looks good for java in the terminal:
java --version
openjdk 16.0.2 2021-07-20
OpenJDK Runtime Environment Homebrew (build 16.0.2+0)
OpenJDK 64-Bit Server VM Homebrew (build 16.0.2+0, mixed mode, sharing)
...but how can I tell the jEdit application where my JRE is.
I tried installing jedit via homebrew too, but the result was the same.
If I run the jar file at the command line then jedit does start up, albeit with these errors showing up in the terminal (significant? maybe not):
% /usr/local/opt/openjdk/bin/java -jar /Applications/jEdit.app/Contents/Java/jedit.jar
12:39:14 [AWT-EventQueue-0] [error] OSXAdapter: Could not talk to EAWT:
12:39:14 [AWT-EventQueue-0] [error] OSXAdapter: java.lang.IllegalAccessException: class macosx.OSXAdapter cannot access class com.apple.eawt.Application (in module java.desktop) because module java.desktop does not export com.apple.eawt to unnamed module @1ed7437b
...
2021-10-13 12:39:15.678 java[44580:3291018] JavaNativeFoundation: GetGlobalVM: Failed to locate @rpath/libjvm.dylib for JNI_GetCreatedJavaVMs(). A JVM must be loaded before calling this function.
So that's a workaround, but I kinda want to be able to click on the application icon!
/usr/libexec/java_home -V
return?16.0.2 (x86_64) "Homebrew" - "OpenJDK 16.0.2" /usr/local/Cellar/openjdk/16.0.2/libexec/openjdk.jdk/Contents/Home
/usr/bin/java --version
return/usr/bin/java --version
returns the same asjava --version
(posted ^)