2 Replies Latest reply: Dec 4, 2012 5:44 AM by Saurabh Aloni
Saurabh Aloni Level 1 Level 1 (0 points)

I cannot execute Java program in XCode for Mountain Lion 10.8.2. Please help me how to execute a Java program.


MacBook Pro (13-inch, Mid 2012), OS X Mountain Lion (10.8.2), JAVA
  • 1. Re: how to execute java programs in xcode
    MrHoffman Level 6 Level 6 (12,455 points)

    Do you have a particular error or message or diagnostic or issue, or something that's particularly wrong with Xcode?  If installed, Java does work, and Java applications can be invoked.

     

    Background: Java was deprecated from OS X a while back, and Java itself was removed from the default OS X 10.8 installation.

     

    Given that Java is now an add-on for OS X, you'll want to check with Oracle — the owner of Java — for OS X kits and tools.

     

    I don't know off-hand if Xcode still particularly supports Java (it was pretty weak, when last I checked), but I'd expect you'll be using makefiles for the work, and I'd also suspect that whatever Java support remains in Xcode will probably be going away in some future version of Xcode.   (If support hasn't already disappeared.  You may be using bash build scripts and makefiles to deal with Java now, or going forward.)

     

    If you don't have access to the Apple developer forums and the discussions of tools available there, then the archives of the Apple Java-Dev mailing list can be a good spot to look for existing discussions, and to post questions related to Java development on OS X.

     

    As for IDEs other than Xcode,  Eclipse or NetBeans or IntelliJ IDEA, and BlueJ all run on OS X, and any of these would probably be a better long-term choices for Java development on OS X.

  • 2. Re: how to execute java programs in xcode
    Saurabh Aloni Level 1 Level 1 (0 points)

    Thank you so much Sir for your help. I downloaded NetBeans Java which is perfectly running now on my Mac.