5

From what I've heard 'JDK' stands for Java Development Kit, and on Debian based systems you install default-jdk to get a running javac. However on Fedora (at least the recent ones) installing java-openjdk won't install javac but you have to install java-openjdk-devel for example.

Do I misunderstand the concept of JDK regarding javac? Or why does a package having a name containing 'jdk' not provide javac on Fedora? I would understand if there was only a java-openjdk-devel because JDK implies 'devel' but then I don't understand what java-openjdk (without the devel) stands for.

frans
  • 1,169

3 Answers3

2

This reflects the upstream project structure. There isn't a separate "OpenJRE" as an open source project — it's just "OpenJDK". Correspondingly, the package description for the base package is "The OpenJDK runtime environment 8", not "JRE".

mattdm
  • 3,011
1

OpenJDK is a name of the project that provides open-source JDK implementation. JRE is the end-user subset of it, without development tools.

java-openjdk is the end-user part of OpenJDK, ie. the JRE.
java-openjdk-devel is for developers - the whole JDK as implemented by the OpenJDK.

gronostaj
  • 58,482
0

installing java-openjdk won't install javac

java-openjdk installs the JRE (Java Runtime Environment).

java-openjdk-devel installs the Java Compiler (in addition to the JRE).

Fedora, Oracle Linux, Red Hat Enterprise Linux, etc.

On the command line, type:

$ su -c "yum install java-1.8.0-openjdk"

The java-1.8.0-openjdk package contains just the Java Runtime Environment. If you want to develop Java programs then install the java-1.8.0-openjdk-devel package.

Source OpenJDK: Download and install

DavidPostill
  • 162,382