Xcode Java templates don't build and run successfully
Java templates in Xcode compile using the current JDK but use a JVMVersion key of 1.4*. This means that after you install J2SE 5.0 Release 4, projects compile with J2SE 5.0 and try to launch using Java 1.4.2.
To work around this issue:
To compile and run with Java 1.4.2: Under Java Compiler Settings for the build target, Set Target VM version and Source Version to 1.4*
To compile and run with J2SE 5.0: Under Pure Java Specific in the project settings, set Target VM Version to 1.5* or 1.5+.
Java developer examples compiled for J2SE 5.0
The examples in /Developer/Examples/Java/ are built with the default compiler, which is now J2SE 5.0. If you compile with the default settings, your build results can only be run on machines with J2SE 5.0 installed.
To compile a sample for use on an earlier version of Java, set the "Target VM version" and "Source Version", available under Java Compiler Settings for the build Target, to 1.4*.
Last updated: 2006-05-23