Okay, that's the crappy story behind why this complexity arise now and was not present earlier. Installing JDK 7 is easy on Mac OS X. (Installing JDK 6 is impossible as of now on Mac OS X Mountain Lion, I've done some reading on this and I couldn't find a way - the main reason is Oracle has not released Mac OS compliant JDK 6 installation. If you know installing JDK 6 on Mac OS X, please post it in the comments). The Oracle guide for installing JDK 7 on Mac OS X is pretty clean so I'm not wasting my time in writing something that is already clean and clear. JDK is installed system-wide and you cannot install it on user basis. You also need admin access for this installation. Installing JDK also installs JRE on your system.
To summarize, the steps are:
Sprouts is an American chain of specialty grocery stores with over 150 locations across the United States. Detective time (itch) (mattie) mac os. Sprouts stores are smaller than a typical supermarket, focusing on fresh foods, produce, healthy foods and vitamins/supplements.
1998 (faryalhussain) mac os. Dock, Desktop & Toolbars. When you fire up a Mac, the first thing you see is the desktop—the great-great-grandchild of the original Mac's home-base screen that changed the world in 1984.There's the Dock, full of colorful icons on a see-through shelf. Sprout uses the latest technology both on its website and in the service. Thanks to this, working with Sprout becomes a pleasure, and finding all the important features is very easy. The Sprout service appeared later than most of the social networking services on this list. Nevertheless, Sprout Social is firmly ranked among the best.
1. Go to http://www.oracle.com/technetwork/java/javase/downloads/index.html and download the appropriate .dmg file (for me it was jdk-7u9-macosx-x64.dmg).
2. The file will take some time to download, it took me like 30 mins. The file will be downloaded in the Downloads folder, can be accessed through Dock. Double click the .dmg file and a Finder window will appear with a box - double click it too and the installation will start. That's it!! A confirmation window will appear when installation is done.
It's that simple!
What sucks is setting up of $JAVA_HOME!!
It took me more than an hour to figure this out! It's also because I'm pretty new to Mac OS.
Okay so where is JDK exactly installed on Max OS? It's here: /Library/Java/JavaVirtualMachines/jdk1.7.0_09.jdk
And where is the bin folder of the JDK, it's here:
/Library/Java/JavaVirtualMachines/jdk1.7.0_09.jdk/Contents/Home/bin
And where the JAVA_HOME should point to?
/Library/Java/JavaVirtualMachines/jdk1.7.0_09.jdk/Contents/Home
JAVA_HOME should point to the home directory and not the bin folder.
How to set up JAVA_HOME ? The real reason I'm writing this post..
Step 1:
Check out whether you already have set up $JAVA_HOME and $PATH. Remember the letters should be capital. Open the terminal and type the following commands
echo $PATH
Sprouts Mac Os Catalina
These will print out the current values of $PATH and $JAVA_HOME. You would probably have some value for your $PATH but it will be blank for $JAVA_HOME.
Step 2:
$PATH and $JAVA_HOME should be present in your .profile file. This file is present in your home folder - it is the place where your terminal opens by default. If .profile file is not present you have to create it! This is the trickest part but it is simple!! Following are the steps:
- Open your terminal and type the command vi .profile This will open the .profile file and if not present will create it.
- Paste the following in the file
Sprouts Mac Os Update
JAVA_HOME=/Library/Java/JavaVirtualMachines/jdk1.7.0_09.jdk/Contents/Home;
PATH=$PATH:$JAVA_HOME;
- Write & quit the file by typing :wq
Sprouts Macros
Now, try to see the values of the $PATH and $JAVA_HOME as specified in the Step 1. In my case they show the following values:
echo $PATH
/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/Library/Java/JavaVirtualMachines/jdk1.7.0_09.jdk/Contents/Home
/Library/Java/JavaVirtualMachines/jdk1.7.0_09.jdk/Contents/Home
Sprouts Mac Os X
Step 3:
Verifying everything. Just once command will verify everything:
$JAVA_HOME/bin/java -version
If this command gives you the Java version that you installed, then you are good to go! In my case it prints out