views:

790

answers:

3

What's the accepted procedure and paths to configure jdk and global library source code for Intellij IDEA on OS X?

+2  A: 

IntelliJ should detect your installed JDK's, as they are in a standard location that Apple provides. If you want source code for the JDK, you can download that from Apple as well. Sign up for a free ADC account and then you can get access.

For global libraries, I've been enjoying the Maven integration in the recent release. It alleviates the need to setup global libraries by pulling things from the Maven repository. It will download source and javadoc jars as well.

osi
+4  A: 

In the 'Project Settings' window, go to 'JDKs' section that you see under'Platform Settings'. Click the little plus sign and choose 'JSDK'. A file chooser should open in the /System/Library/Frameworks/JavaVM.framework/Versions directory. If not then just navigate to it. There you can choose the version you would like to add.

St3fan
Just to add a data point, on IDEA 9.0.2 I created a project and it wouldn't let me choose a JDK until *after* I'd finished creating the project. The widget wouldn't show me any files initially, but I was able to set it up after the project had been created.
Lyle