I'm on Ubuntu MATE 18.04. All the jnlp applications I tried give execution error. After inspection, some libraries seem to be missing in Java.
So I removed everything, started installation again, and found that apt-get install icedtea-8-plugin depends on:
ca-certificates-java default-jre default-jre-headless icedtea-8-plugin icedtea-netx librhino-java libtagsoup-java openjdk-11-jre openjdk-11-jre-headless
While it is expected to depend on openjdk-8, not 11 (according to ubuntu packages website). I suspect that jdk-11 does not include some libraries required for this.
My guess is that I installed some PPA that now produces this situation where jdk-11 is a more up to date choice than any jdk-8 package. So, how can I achieve that icedtea-8 is installed with openjdk-8, and not 11?
EDIT: This is the output when I try to launch from firefox a jnlp application:
Denying permission: ("java.lang.RuntimePermission" "accessClassInPackage.sun.util.resources") net.sourceforge.jnlp.LaunchException: Fatal: Launch Error: Could not launch JNLP file. The application has not been initialized, for more information execute javaws/browser from the command line and send a bug report. at net.sourceforge.jnlp.Launcher.launchApplication(Launcher.java:582) ... Running jdk9+ ? java.lang.ClassNotFoundException: sun/misc/JarIndex ... java.io.FileNotFoundException: /home/roman/.config/icedtea-web/deployment.properties (No existe el archivo o el directorio) at java.base/java.io.FileInputStream.open0(Native Method)
The ClassNotFoundException: sun/misc/JarIndex is what made me thought that is due to the dependency on jdk11, since this class seems to have been removed in Java 9.
I tried installing only openjdk-8, and then build icedtea from source. Nevertheless, when I finished, it was not detected by firefox (maybe some command was missing).
Also, find below the output of those commands (after trying installing according to your answer):
roman@roman-desktop:~$ update-java-alternatives -l java-1.11.0-openjdk-amd64 1111 /usr/lib/jvm/java-1.11.0-openjdk-amd64 java-1.8.0-openjdk-amd64 1081 /usr/lib/jvm/java-1.8.0-openjdk-amd64 roman@roman-desktop:~$ which javaws /usr/bin/javaws