Processing not working with EndeavourOS

I installed processing language, and I am able to open it up just fine.

However when I run it I get a bunch of different errors:

image

Exception in thread "Thread-7" java.lang.RuntimeException: Exception while attempting /usr/lib/jvm/java-8-openjdk/bin/java -agentlib:jdwp=transport=dt_socket,address=8200,server=y,suspend=y,quiet=y -Djna.nosys=true -Djava.ext.dirs=/usr/lib/jvm/java-8-openjdk/lib/ext -Djava.library.path=:/usr/share/processing/core/library:/usr/java/packages/lib/amd64:/usr/lib64:/lib64:/lib:/usr/lib -cp /tmp/sketch_201013a610259254011698223temp:/usr/share/processing/core/library/gluegen-rt-natives-linux-i586.jar:/usr/share/processing/core/library/jogl-all-natives-windows-i586.jar:/usr/share/processing/core/library/core.jar:/usr/share/processing/core/library/jogl-all-natives-macosx-universal.jar:/usr/share/processing/core/library/gluegen-rt-natives-linux-armv6hf.jar:/usr/share/processing/core/library/gluegen-rt-natives-macosx-universal.jar:/usr/share/processing/core/library/gluegen-rt-natives-linux-amd64.jar:/usr/share/processing/core/library/jogl-all-natives-linux-aarch64.jar:/usr/share/processing/core/library/gluegen-rt.jar:/usr/share/processing/core/library/jogl-all-natives-linux-i586.jar:/usr/share/processing/core/library/jogl-all.jar:/usr/share/processing/core/library/jogl-all-natives-linux-armv6hf.jar:/usr/share/processing/core/library/gluegen-rt-natives-windows-i586.jar:/usr/share/processing/core/library/gluegen-rt-natives-linux-aarch64.jar:/usr/share/processing/core/library/jogl-all-natives-windows-amd64.jar:/usr/share/processing/core/library/gluegen-rt-natives-windows-amd64.jar:/usr/share/processing/core/library/jogl-all-natives-linux-amd64.jar:/usr/lib/jvm/java-8-openjdk/jre/lib/rt.jar:/usr/share/processing/lib/ant.jar:/usr/share/processing/lib/ant-launcher.jar:/usr/share/processing/lib/jna.jar:/usr/share/processing/lib/jna-platform.jar:/usr/share/processing/lib/pde.jar:/usr/share/processing/core/library/core.jar:/usr/share/processing/core/library/gluegen-rt.jar:/usr/share/processing/core/library/gluegen-rt-natives-linux-aarch64.jar:/usr/share/processing/core/library/gluegen-rt-natives-linux-amd64.jar:/usr/share/processing/core/library/gluegen-rt-natives-linux-armv6hf.jar:/usr/share/processing/core/library/gluegen-rt-natives-linux-i586.jar:/usr/share/processing/core/library/gluegen-rt-natives-macosx-universal.jar:/usr/share/processing/core/library/gluegen-rt-natives-windows-amd64.jar:/usr/share/processing/core/library/gluegen-rt-natives-windows-i586.jar:/usr/share/processing/core/library/jogl-all.jar:/usr/share/processing/core/library/jogl-all-natives-linux-aarch64.jar:/usr/share/processing/core/library/jogl-all-natives-linux-amd64.jar:/usr/share/processing/core/library/jogl-all-natives-linux-armv6hf.jar:/usr/share/processing/core/library/jogl-all-natives-linux-i586.jar:/usr/share/processing/core/library/jogl-all-natives-macosx-universal.jar:/usr/share/processing/core/library/jogl-all-natives-windows-amd64.jar:/usr/share/processing/core/library/jogl-all-natives-windows-i586.jar:/usr/share/processing/modes/java/mode/antlr.jar:/usr/share/processing/modes/java/mode/classpath-explorer-1.0.jar:/usr/share/processing/modes/java/mode/com.ibm.icu.jar:/usr/share/processing/modes/java/mode/JavaMode.jar:/usr/share/processing/modes/java/mode/jdi.jar:/usr/share/processing/modes/java/mode/jdimodel.jar:/usr/share/processing/modes/java/mode/jdtCompilerAdapter.jar:/usr/share/processing/modes/java/mode/jsoup-1.7.1.jar:/usr/share/processing/modes/java/mode/org.eclipse.core.contenttype.jar:/usr/share/processing/modes/java/mode/org.eclipse.core.jobs.jar:/usr/share/processing/modes/java/mode/org.eclipse.core.resources.jar:/usr/share/processing/modes/java/mode/org.eclipse.core.runtime.jar:/usr/share/processing/modes/java/mode/org.eclipse.equinox.common.jar:/usr/share/processing/modes/java/mode/org.eclipse.equinox.preferences.jar:/usr/share/processing/modes/java/mode/org.eclipse.jdt.core.jar:/usr/share/processing/modes/java/mode/org.eclipse.osgi.jar:/usr/share/processing/modes/java/mode/org.eclipse.text.jar:/usr/share/processing/modes/java/mode/org.netbeans.swing.outline.jar -ea processing.core.PApplet --display=-1 --sketch-path=/tmp/untitled1894016874808851229sketches/sketch_201013a sketch_201013a
	at processing.core.PApplet.exec(PApplet.java:3570)
	at processing.mode.java.runner.Runner$1.run(Runner.java:498)
	at java.lang.Thread.run(Thread.java:748)
Caused by: java.io.IOException: Cannot run program "/usr/lib/jvm/java-8-openjdk/bin/java": error=2, No such file or directory
	at java.lang.ProcessBuilder.start(ProcessBuilder.java:1048)
	at java.lang.Runtime.exec(Runtime.java:621)
	at java.lang.Runtime.exec(Runtime.java:486)
	at processing.core.PApplet.exec(PApplet.java:3568)
	... 2 more
Caused by: java.io.IOException: error=2, No such file or directory
	at java.lang.UNIXProcess.forkAndExec(Native Method)
	at java.lang.UNIXProcess.<init>(UNIXProcess.java:247)
	at java.lang.ProcessImpl.start(ProcessImpl.java:134)
	at java.lang.ProcessBuilder.start(ProcessBuilder.java:1029)
	... 5 more

It appears that Java is installed on my system as when I type java in terminal, then it outputs some java related stuff:

Usage: java [-options] class [args...]
           (to execute a class)
   or  java [-options] -jar jarfile [args...]
           (to execute a jar file)
where options include:
    -d32          use a 32-bit data model if available
    -d64          use a 64-bit data model if available
    -server       to select the "server" VM
                  The default VM is server,
                  because you are running on a server-class machine.


    -cp <class search path of directories and zip/jar files>
    -classpath <class search path of directories and zip/jar files>
                  A : separated list of directories, JAR archives,
                  and ZIP archives to search for class files.
    -D<name>=<value>
                  set a system property
    -verbose:[class|gc|jni]
                  enable verbose output
    -version      print product version and exit
    -version:<value>
                  Warning: this feature is deprecated and will be removed
                  in a future release.
                  require the specified version to run
    -showversion  print product version and continue
    -jre-restrict-search | -no-jre-restrict-search
                  Warning: this feature is deprecated and will be removed
                  in a future release.
                  include/exclude user private JREs in the version search
    -? -help      print this help message
    -X            print help on non-standard options
    -ea[:<packagename>...|:<classname>]
    -enableassertions[:<packagename>...|:<classname>]
                  enable assertions with specified granularity
    -da[:<packagename>...|:<classname>]
    -disableassertions[:<packagename>...|:<classname>]
                  disable assertions with specified granularity
    -esa | -enablesystemassertions
                  enable system assertions
    -dsa | -disablesystemassertions
                  disable system assertions
    -agentlib:<libname>[=<options>]
                  load native agent library <libname>, e.g. -agentlib:hprof
                  see also, -agentlib:jdwp=help and -agentlib:hprof=help
    -agentpath:<pathname>[=<options>]
                  load native agent library by full pathname
    -javaagent:<jarpath>[=<options>]
                  load Java programming language agent, see java.lang.instrument
    -splash:<imagepath>
                  show splash screen with specified image
See http://www.oracle.com/technetwork/java/javase/documentation/index.html

A friend of mine suggested me to do this:

mkdir -p ~/programs/processing
cd ~/programs/processing
wget https://github.com/processing/processing/releases/download/processing-0270-3.5.4/processing-3.5.4-linux64.tgz
tar -xf processing-3.5.4-linux64.tgz
cd processing-3.5.4
./processing