SyntaxHighlighter JS


Java on Mac OSX

Notes to myself about Java on Mac OS X since I always forget and have to Google it every time.

  • How do you find all the Java installed on your Mac?
    /usr/libexec/java_home -V

  • How do you set JAVA_HOME to a specific version?
    export JAVA_HOME=`/usr/libexec/java_home -v 1.6`

  • How do you execute a specific version of Java to run?
    /usr/libexec/java_home -v 1.6 --exec javac -version

  • What is the difference between the Java in /System/Library and /Library?
    The Java in /System/Library is the version of Java from Apple. Apple uses it for its system runtime so do not touch or modify it.  The Java in /Library is what you installed from Sun.

  • Where do you put Java Extensions?
    In directory /Library/Java/Extensions

No comments:

Post a Comment