methusalah / OpenRTS

Real-Time Strategy game 3D engine coded in pure java
MIT License
1.29k stars 151 forks source link

Unable to run on linux? #107

Open dosaki opened 7 years ago

dosaki commented 7 years ago

Hi,

I've evaluating OpenRTS to see how good it would be to implement a game. I've seen some of the youtube videos and it looked rather nice.

The problem is that I can't seem to run this on Linux. I've seen #106 but I still get a problem after the dependencies are resolved.

I'm running Linux 4.9.15-1-lts x86_64 GNU/Linux

The error that I get is:

$ ./gradlew run
Configuration on demand is an incubating feature.
:core:compileJavaNote: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.

:core:processResources
:core:classes
:core:runMar 21, 2017 12:43:01 PM app.OpenRTSApplication main
INFO: seed : 2
Mar 21, 2017 12:43:01 PM com.jme3.system.JmeDesktopSystem initialize
INFO: Running on jMonkeyEngine 3.1-stable
 * Branch: HEAD
 * Git Hash: af04bf9
 * Build Date: 2017-02-13
Mar 21, 2017 12:43:02 PM com.jme3.app.LegacyApplication handleError
SEVERE: Uncaught exception thrown in Thread[jME3 Main,5,main]
java.lang.UnsatisfiedLinkError: org.lwjgl.opengl.LinuxDisplay.nSetClassHint(JJJJ)V
    at org.lwjgl.opengl.LinuxDisplay.nSetClassHint(Native Method)
    at org.lwjgl.opengl.LinuxDisplay.setClassHint(LinuxDisplay.java:800)
    at org.lwjgl.opengl.LinuxDisplay.createWindow(LinuxDisplay.java:500)
    at org.lwjgl.opengl.Display.createWindow(Display.java:306)
    at org.lwjgl.opengl.Display.create(Display.java:848)
    at org.lwjgl.opengl.Display.create(Display.java:757)
    at com.jme3.system.lwjgl.LwjglDisplay.createContext(LwjglDisplay.java:143)
    at com.jme3.system.lwjgl.LwjglAbstractDisplay.initInThread(LwjglAbstractDisplay.java:113)
    at com.jme3.system.lwjgl.LwjglAbstractDisplay.run(LwjglAbstractDisplay.java:211)
    at java.lang.Thread.run(Thread.java:745)

Exception: java.lang.NullPointerException thrown from the UncaughtExceptionHandler in thread "jME3 Main"

:core:jar
:example:compileJava
:example:processResources
:example:classes
:example:runMar 21, 2017 12:43:20 PM app.OpenRTSApplication main
INFO: seed : 2
Mar 21, 2017 12:43:20 PM com.jme3.system.JmeDesktopSystem initialize
INFO: Running on jMonkeyEngine 3.1-stable
 * Branch: HEAD
 * Git Hash: af04bf9
 * Build Date: 2017-02-13
Mar 21, 2017 12:43:21 PM com.jme3.app.LegacyApplication handleError
SEVERE: Uncaught exception thrown in Thread[jME3 Main,5,main]
java.lang.UnsatisfiedLinkError: org.lwjgl.opengl.LinuxDisplay.nSetClassHint(JJJJ)V
    at org.lwjgl.opengl.LinuxDisplay.nSetClassHint(Native Method)
    at org.lwjgl.opengl.LinuxDisplay.setClassHint(LinuxDisplay.java:800)
    at org.lwjgl.opengl.LinuxDisplay.createWindow(LinuxDisplay.java:500)
    at org.lwjgl.opengl.Display.createWindow(Display.java:306)
    at org.lwjgl.opengl.Display.create(Display.java:848)
    at org.lwjgl.opengl.Display.create(Display.java:757)
    at com.jme3.system.lwjgl.LwjglDisplay.createContext(LwjglDisplay.java:143)
    at com.jme3.system.lwjgl.LwjglAbstractDisplay.initInThread(LwjglAbstractDisplay.java:113)
    at com.jme3.system.lwjgl.LwjglAbstractDisplay.run(LwjglAbstractDisplay.java:211)
    at java.lang.Thread.run(Thread.java:745)

Exception: java.lang.NullPointerException thrown from the UncaughtExceptionHandler in thread "jME3 Main"

The error seems to be specific to Linux though. I've noticed that OpenRTS includes some lwjgl native libraries in core/ and example/. Is it something related to this?

methusalah commented 7 years ago

It seems that the dependencies are correct.

Since I have no skill in Linux and no environnement to test it, I can't be of much help here. But I have the feeling that it is much jMonkey related than OpenRTS. Maybe you can try to ask for some help on the OpenRTS forum (which is embed into jMonkey forum)

dosaki commented 7 years ago

I see. I'll try just that. Thank you very much.