The latest developer release of Mac OS X 10.7 Lion excludes support for Rosetta (used to run PowerPC code on Intel Macs), Front Row, and Oracle's Java runtime, although Apple includes a mechanism.
Apple has removed the Java runtime from its upcoming Mac OS X Lion, according to a report based on firsthand experience with a preview release of the OS.
Appleinsider reports that the latest developer release of Mac OS X 10.7 Lion removes both Java and Rosetta, the package used to run PowerPC code on Intel-based Macs. But according to the fanboi news site, Lion includes a mechanism for automatically downloading the latest version of Java for the Mac.
In late October, Apple caused a fair amount of unrest among Java developers when, in the release notes of a Java update, it said that Java on Mac had been 'deprecated' and that it 'may be removed from future versions of Mac OS.' Now, it has been removed, but the future of Java development on Macs is secure. In November, Apple and Oracle announced that they would collaborate on a Mac-based incarnation of OpenJDK, an open source version of Java.
Apple said it would contribute 'most of the key components, tools and technology' needed for a Java SE 7 implementation on Mac OS X, including a 32-bit and 64-bit HotSpot-based Java virtual machine, class libraries, a networking stack, and base code for a new graphical client.
The average Joe isn't likely to miss Java on Lion. Few consumer desktop applications use the technology. But many business apps still use it, and of course, Java developers need the runtime on their machines. According to Appleinsider, if you try to run a Java app on Lion, the OS will look for the latest version of the runtime and download it – with the user's approval.
Rosetta was also previously deprecated by Apple, and the company barred applications using both Rosetta and Java from the new Mac App Store. With Snow Leopard, the current version of Mac OS X, Rosetta is not installed by default, but users could install it if they chose to. Now it has been completely removed. ®
See JDK 7 and JRE 7 Installation Guide for general information about installing JDK 7 and JRE 7.
See the Mac OS X Platform Install FAQ for general information about installing JDK 7 on Mac OS X.
Note that installing the JDK on a Mac is performed on a system wide basis, for all users, and administrator privileges are required. You cannot install Java for a single user.
Installing the JDK also installs the JRE. The one exception is that the system will not replace the current JRE with a lower version. To install a lower version of the JRE, first uninstall the current version.
When you download the Java Development Kit (JDK), the associated Java Runtime Environment (JRE) is installed at the same time. The JavaFX SDK and Runtime are also installed and integrated into the standard JDK directory structure.
Depending on your processor, the downloaded file has one of the following names:
Where <version> is 6 or later.
1. Download the file. Before the file can be downloaded, you must accept the license agreement.
2. From either the Downloads window of the browser, or from the file browser, double click the .dmg file to launch it.
3. A Finder window appears containing an icon of an open box and the name of the .pkg file Double click the package icon to launch the Install app.
4. The Install app displays the Introduction window. Click Continue.
4a. Note that, in some cases, a Destination Select window appears. This is a bug, as there is only one option available. If you see this window, select Install for all users of this computer to enable the continue button. Click Continue.
5. The Installation Type window appears. Click Install.
6. A window appears which says 'Installer is trying to install new software. Type your password to allow this.' Enter the Administrator login and password and click Install Software.
7. The software is installed and a confirmation window appears. Click the ReadMe for more information about the installation.
After the software is installed, delete the dmg file if you want to save disk space.
A: If you have not yet installed Apple's Java Mac OS X 2012-006 update, then you are still using a version of Apple Java 6 that includes the plug-in and the Java Preferences app. See Note for Users of Macs that Include Apple Java 6 Plug-in.
There can be multiple JDKs installed on a system – as many as you wish.
When launching a Java application through the command line, the system uses the default JDK. It is possible for the version of the JRE to be different than the version of the JDK.
You can determine which version of the JDK is the default by typing java -version in a Terminal window. If the installed version is 7u6, you will see a string that includes the text 1.7.0_06. For example:
To run a different version of Java, either specify the full path, or use the java_home tool:
For more information, see the java_home(1) man page.
To uninstall the JDK, you must have Administrator privileges and execute the remove command either as root or by using the sudo(8) tool.
Navigate to /Library/Java/JavaVirtualMachines and remove the directory whose name matches the following format:*
For example, to uninstall 7u6:
Do not attempt to uninstall Java by removing the Java tools from /usr/bin. This directory is part of the system software and any changes will be reset by Apple the next time you perform an update of the OS.
*The 7u4 and 7u5 releases were installed into a directory that does not follow this format. To uninstall 7u4 or 7u5, remove the 1.7.0.jdk directory from the same location.