What is the difference between openjdk and jdk?
The main difference between OpenJDK and JDK lies in their openness and license.
- Openness: OpenJDK is an open-source Java development kit led by Oracle and released under the GPL license. Its source code is publicly available for anyone to view, modify, and distribute. In contrast, JDK (Java Development Kit) is a Java development kit provided by Oracle that is not open-source, and its source code is not publicly available.
- License: OpenJDK uses the GPL license, which means that software developed using OpenJDK must comply with the GPL, including making the source code public and keeping it open source. On the other hand, JDK uses the Oracle Binary Code License, which means that software developed using JDK does not need to make the source code public, but must comply with other provisions of the license.
Apart from these main differences, OpenJDK and JDK are essentially the same in functionality, both providing Java development tools like the Java compiler (javac), Java virtual machine (JVM), and Java standard library. These toolkits can both be used for developing and running Java applications, with differences only in license and openness.