Sunday, April 28, 2024
 Popular · Latest · Hot · Upcoming
6
rated 0 times [  6] [ 0]  / answers: 1 / hits: 16497  / 2 Years ago, thu, september 15, 2022, 7:51:25

I want to install Java on my computer so that I can develop programs and I came across this page on Java in the Ubuntu community documentation. It says:




Java is a technology from Oracle (formerly: Sun Microsystems). There
are several implementations, of which five will be discussed here:




  • OpenJDK: The primary goal of the OpenJDK project is to produce an open-source implementation of the Java SE Platform (6 and 7). This
    is the default version of Java that Ubuntu uses and is the easiest to
    install.

  • Oracle (Sun) Java 6: Oracle (Sun) Java 6 is the reference implementation for Java 6.

  • Oracle Java 7: Oracle Java 7 is the reference implementation for Java 7.

  • IBM Java: IBM Java is the preferred Java solution on PowerPC machines. It is a reimplementation with a Just-In-Time Compiler. It is
    only available from IBM's website.

  • GNU Compiler: A Java compiler made by GNU. Only developers should have to install this.




I read the contents but still am a little confused. Are they all different versions of JDK? If not, then what?



And which one would you prefer?


More From » java

 Answers
6

Are they all different versions of JDK? If not, then what?




They are different implementations of Java/development kits for Java (JDK). Java is a standard platform, and all of these implement that platform in their own way. Of these:




  • OpenJDK and GNU Compiler are the only ones that are open source. I usually prefer them -- the ease of installation (apt-get or Software Center) is a big factor.

    • OpenJDK in particular is derived mostly from the "official" Java source code that Oracle/Sun open sourced; it is backed by Oracle.


  • Oracle Java 6 and 7 are "the" Java, if you will, from the company that invented Java (that was Sun, but Oracle bought them a while back). That's why they are called reference implementations. You may want to use them if you are using Oracle JDK on another platform too, or if OpenJDK is giving you problems.

    • The 6 and 7 refer to versions of the language/platform. 7 is newer and has more features, but has been tested less; 6 is extremely mature and stable. I'd prefer 6 if you are just starting out.


  • Contrary to the wiki, IBM makes JDKs/JREs for all platforms, although theirs might be the only one for the PowerPC.






If you are starting out in programming, almost any of these will be a good fit. Go for OpenJDK just because its easy to install.



The only experience I have in differentiating these is compiling in a low-resource environment (128-192MB RAM - a VPS); I found Oracle Java 6 JDK worked best for one program (i.e succeeded) and IBM Java 6 JDK for another...


[#37983] Thursday, September 15, 2022, 2 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
rhaeams

Total Points: 115
Total Questions: 111
Total Answers: 103

Location: Burundi
Member since Wed, Nov 25, 2020
4 Years ago
;