Java for Mac OS X

Discussion in 'Mac Help/Tips' started by macktheknife, May 15, 2002.

  1. macktheknife macrumors 6502a

    macktheknife

    Joined:
    Jan 24, 2002
    #1
    Quick question: Does anyone know whether a Java Developer Kit (JDK) is available for Mac OS X? I've tried surfing on Sun's Java website at www.java.sun.com but it appears that JDK is available only for Windows, Linux, and Solaris. I'm trying to teach myself Java this summer.

    Thanks!
     
  2. evildead macrumors 65816

    evildead

    Joined:
    Jun 18, 2001
    Location:
    WestCost, USA
    #2
    Apple Makes one

    Now do you want an IDE? or can you do it the old fashoned way... command line and text edittor? you can use the built in OS X terminal to do it. The jdk is standard for all platforms. "code once, run everywhere"

    #javac FileName.java

    to compile

    #java FileName

    to run

    ... it will print out errors and line numbers if it fails on compile.

    You can get a free IDE from Apple. Dowload the Apple developers kit off apple.com. You do have to fill out a form but you dont have to join the Apple dev club. that costs money... Its a cool deal.. if you into that sort of thing... so read about it.

    Borland Make Jbuilder 6.0... just out for OS X. Jbuilder 5 was for OS 9.. but you want to code java in X. Its very nice... for an IDE.. its my favoret. But.. its not free.. and it can be a little pricy. you can get trial versions of it to check it out.


    Code warrior make one too.. I hear that version 8 is out or comming out soon. I paied for a copy of verion 4.0 a few years ago.. but it was not very good. it was hard to understand and use. They may have gotten better.

    Forte from Sun is pretty good for a free one. I have even used it for enterproice level programming at work. But .... no Mac version yet. I bet Sun will make one now that Apple went UNIX.


    -evildead


    The Apple IDE needs work but its ok.
     
  3. macktheknife thread starter macrumors 6502a

    macktheknife

    Joined:
    Jan 24, 2002
    #3
    Huh?

    This link on the Apple Developers' website (http://developer.apple.com/java/index.html) says that Java 2 Standard Edition (J2SE) is available, but I can't seem to find it! Sorry to sound stupid, but does anyone know where I can locate a copy on the site? Thanks!
     
  4. Taft macrumors 65816

    Taft

    Joined:
    Jan 31, 2002
    Location:
    Chicago
    #4
    It all comes standard.

    java, javac and all of the rest of the debug tools, dev tools and libraries come standard with Apple's Developer Tools. java (the JVM and runtime environment, that is) comes standard on ALL OS X systems.

    To get the Apple Dev Tools, go to developer.apple.com. You'll need to sign up for a developer ID. Once you log in, you can download the latest tools or send away for them.

    The way the dev tools installs is not the same as on Windows or Linux or Solaris. All of the executables are located in /usr/bin (so you'll have to provide Java IDE's and tools with /usr for the JAVA_HOME variable or home directory of your JDK). Also, all of the libraries are located under a system toolkit. They are either in /Library or /System/Library (I can't remember, sorry).

    Other than that, every pure Java program I've tried under OS X works flawlessly. (And compiles flawlessly, too) I've got Java stuff for work compiling and running on my Macs. I've even got Java working with Mathematica via JLink on my laptop. I use it to get to my MySQL database on my server machine. Pretty flippin' sweet to get data into Mathematica via Java.

    Hope this answers the question you were asking.

    Taft
     
  5. macktheknife thread starter macrumors 6502a

    macktheknife

    Joined:
    Jan 24, 2002
    #5
    Hum . . .

    I that I'm a complete novice at this, so please bear with me. It appears that Mac OS X already includes J2SE. Does anyone know how I can run it? Or is terminal my only option?
     
  6. macktheknife thread starter macrumors 6502a

    macktheknife

    Joined:
    Jan 24, 2002
  7. Taft macrumors 65816

    Taft

    Joined:
    Jan 31, 2002
    Location:
    Chicago
    #7
    Also, if you are getting serious into Java programming, just remember that all the free java tools out there will work with OS X. Borland provides a version of thier IDE, JBuilder for OS X. Also Apache makes a lot of great Java tools. Check out Ant for auto builds (like a sensible version of 'make') and Tomcat for making web pages via Java servlets.

    All free!! FREE!!!!!

    Taft
     
  8. Taft macrumors 65816

    Taft

    Joined:
    Jan 31, 2002
    Location:
    Chicago
    #8
    Just one more thing....

    The Apple Developer Toolkit also includes tools for creating Mac OS X friendly packages for Java programs. This allows you to create double click-able programs that do all of the work of an equivilant MS .bat file or a Unix style shell script (which incidently also work under OS X).

    Makes it very Mac friendly.

    Taft
     

Share This Page