Search code examples
macospluginsjavajava-home

What path does one specify for JAVA_HOME on a Mac OS environment?


When an application or plug-in install states that the JAVA_HOME variable point you my JDK, what export statement do I need to put in my .bash_profile?


Solution

  • Browse to: /System/Library/Frameworks/JavaVM.Framework/Versions/

    Then, pick an alias to a version or 'CurrentJDK'.

    export JAVA_HOME=/System/Library/Frameworks/JavaVM.Framework/Versions/CurrentJDK/Home

    then add $JAVA_HOME to your PATH.