java-decompiler / jd-gui

A standalone Java Decompiler GUI
GNU General Public License v3.0
14.09k stars 2.4k forks source link

About Apple M1 Pro #378

Open cafe-old-babe opened 2 years ago

cafe-old-babe commented 2 years ago

download from the official website jd-gui-osx-1.6.6.tar running tips image local inclusion Java environment image universalJavaApplicationStub.sh change -v to -V ,solve this problem image

cafe-old-babe commented 2 years ago

System version: macOS Monterey 12.1

JensHouses commented 2 years ago

You just need to remove the plus sign: change 1.8+ to 1.8 in the Info.plist file:

screenshot

As you can see the command -F -v with the arg 1.8+ doesn't work!

Bildschirmfoto 2022-02-10 um 01 04 34
EVINK commented 2 years ago

You just need to remove the plus sign: change 1.8+ to 1.8 in the Info.plist file: screenshot

As you can see the command -F -v with the arg 1.8+ doesn't work! Bildschirmfoto 2022-02-10 um 01 04 34

This doesn't work for me, just simply change -v to -V in universalJavaApplicationStub.sh is OK.

zhanggang807 commented 2 years ago

You just need to remove the plus sign: change 1.8+ to 1.8 in the Info.plist file: screenshot

As you can see the command -F -v with the arg 1.8+ doesn't work! Bildschirmfoto 2022-02-10 um 01 04 34

which app you use to open plist file???

zhanggang807 commented 2 years ago

@JensHouses

JensHouses commented 2 years ago

@zhanggang807 I used Xcode to open it but u can edit it from the terminal.

go to the JD-GUI.app/Contents folder and type in: plutil -replace JavaX.JVMVersion -string 1.8 Info.plist

will Change the "1.8+" to the value "1.8".

cha2hyun commented 1 year ago

image @JensHouses Doesnt work for me Any help?

JensHouses commented 1 year ago

what version of java do you have?

you can check your Version using this command: /usr/libexec/java_home -F -V Gives you an output like this one

Matching Java Virtual Machines (2):
    19 (arm64) "Homebrew" - "OpenJDK 19" /opt/homebrew/Cellar/openjdk/19/libexec/openjdk.jdk/Contents/Home
    1.8.333.02 (x86_64) "Oracle Corporation" - "Java" /Library/Internet Plug-Ins/JavaAppletPlugin.plugin/Contents/Home
/opt/homebrew/Cellar/openjdk/19/libexec/openjdk.jdk/Contents/Home
cha2hyun commented 1 year ago

https://github.com/java-decompiler/jd-gui/pull/379 It works for me thanks

liudanking commented 1 year ago

@zhanggang807 I used Xcode to open it but u can edit it from the terminal.

go to the JD-GUI.app/Contents folder and type in: plutil -replace JavaX.JVMVersion -string 1.8 Info.plist

will Change the "1.8+" to the value "1.8".

It works for me, many thanks!