How to set JAVA_HOME on OSX 10.8 for Max 6.1.1

Funk Eater's icon

I tried to get Java running again after updating to 6.1.1 but have trouble to get Max to use the right JDK.
It looks like Max uses the Apple supplied JDK instead of the Oracle JDK I installed. I added the right JAVA_HOME to my .profile and in terminal everything is fine, but Max seams to ignore it. How can I check which JDK Max is using? And how can I force Max to use the right one?