Search code examples
javadllcompiler-errorslwjgljava.library.path

Why LWJGL .dll files do not work after .jar exporting?


After exporting my game to jar it does not work. Exception in thread "main" java.lang.UnsatisfiedLinkError: no jinput-dx8_64 in java.library.path

I read that I have to put the files anywhere in my computer and add the .dll files path to java.libraty.path, but, will it work if I try the game in another computer?

Tanks :D


Solution

  • If you are working on windows, just add the path of the dll file along with the java path in environment variable. For example. If your dll file is present in jdk/jre/bin,path=C:\Program Files\Java\jdk1.8.0_25\jre\bin. Just try this one. Once worked for me.