GithubHelp home page GithubHelp logo

Comments (5)

scmurdock avatar scmurdock commented on August 20, 2024

FYI I've also tested the following, to no avail:

             System.setProperty("java.library.path", "/usr/lib/i386-linux-gnu");

from jkeymaster.

tulskiy avatar tulskiy commented on August 20, 2024

Hi, Sean,

I don't think modifying these variables from code will work, try adding these params to the java vm as:

java -Djava.library.path=/usr/lib -cp example.jar YourClass

Also, are you on a 64-bit OS? I'm using this library on a Ubuntu 11.10 32-bit and all works fine.

from jkeymaster.

scmurdock avatar scmurdock commented on August 20, 2024

I'm on a 32 bit OS. I tried the following command. The jar file has a main
method specified when building from eclipse and it even tries to run (hence
the original error). Yet after using the options specified I invariably get
this:

$ java -D java.library.path=/usr/lib -cp JavaKeyTest.jar
Exception in thread "main" java.lang.NoClassDefFoundError:
java/library/path=/usr/lib
Caused by: java.lang.ClassNotFoundException: java.library.path=.usr.lib
at java.net.URLClassLoader$1.run(URLClassLoader.java:217)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:205)
at java.lang.ClassLoader.loadClass(ClassLoader.java:321)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294)
at java.lang.ClassLoader.loadClass(ClassLoader.java:266)
Could not find the main class: java.library.path=/usr/lib. Program will
exit.

On Thu, Nov 10, 2011 at 10:30 AM, Denis Tulskiy <
[email protected]>wrote:

Hi, Sean,

I don't think modifying these variables from code will work, try adding
these params to the java vm as:

java -Djava.library.path=/usr/lib -cp example.jar YourClass

Also, are you on a 64-bit OS? I'm using this library on a Ubuntu 11.10
32-bit and all works fine.


Reply to this email directly or view it on GitHub:
#3 (comment)

from jkeymaster.

tulskiy avatar tulskiy commented on August 20, 2024

There should be no space after -D, and you need to use -jar instead of
-cp if you're running just a jar.

java -Djava.library.path=/usr/lib -jar JavaKeyTest.jar

On Fri, Nov 11, 2011 at 1:45 PM, scmurdock <
[email protected]>wrote:

I'm on a 32 bit OS. I tried the following command. The jar file has a main
method specified when building from eclipse and it even tries to run (hence
the original error). Yet after using the options specified I invariably get
this:

$ java -D java.library.path=/usr/lib -cp JavaKeyTest.jar
Exception in thread "main" java.lang.NoClassDefFoundError:
java/library/path=/usr/lib
Caused by: java.lang.ClassNotFoundException: java.library.path=.usr.lib
at java.net.URLClassLoader$1.run(URLClassLoader.java:217)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:205)
at java.lang.ClassLoader.loadClass(ClassLoader.java:321)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294)
at java.lang.ClassLoader.loadClass(ClassLoader.java:266)
Could not find the main class: java.library.path=/usr/lib. Program will
exit.

On Thu, Nov 10, 2011 at 10:30 AM, Denis Tulskiy <
[email protected]>wrote:

Hi, Sean,

I don't think modifying these variables from code will work, try adding
these params to the java vm as:

java -Djava.library.path=/usr/lib -cp example.jar YourClass

Also, are you on a 64-bit OS? I'm using this library on a Ubuntu 11.10
32-bit and all works fine.


Reply to this email directly or view it on GitHub:
#3 (comment)


Reply to this email directly or view it on GitHub:
#3 (comment)


Best,
Denis Tulskiy

from jkeymaster.

scmurdock avatar scmurdock commented on August 20, 2024

Thanks Denis. That worked:

java -Djava.library.path=/usr/lib -jar JavaKeyTest.jar

Nov 11, 2011 7:51:12 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Starting X11 global hotkey provider
Nov 11, 2011 7:51:13 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{ctrl alt D}
Nov 11, 2011 7:51:13 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{shift ctrl 0}
Nov 11, 2011 7:51:13 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{shift ctrl PLUS}
Nov 11, 2011 7:51:13 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{shift ctrl INSERT}
Nov 11, 2011 7:51:13 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{shift ctrl ESCAPE}
Nov 11, 2011 7:51:13 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{shift ctrl BACK_QUOTE}
Nov 11, 2011 7:51:13 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{shift ctrl SLASH}
Nov 11, 2011 7:51:13 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{shift ctrl BACK_SLASH}
Nov 11, 2011 7:51:13 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{shift ctrl DIVIDE}
Nov 11, 2011 7:51:13 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{shift ctrl MULTIPLY}
Nov 11, 2011 7:51:13 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{shift ctrl ENTER}
Nov 11, 2011 7:51:13 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{shift ctrl MINUS}
Nov 11, 2011 7:51:13 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{shift ctrl BACK_QUOTE}
Nov 11, 2011 7:51:13 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{shift ctrl RIGHT}
Nov 11, 2011 7:51:13 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{shift ctrl INSERT}
Nov 11, 2011 7:51:13 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{shift ctrl DELETE}
Nov 11, 2011 7:51:13 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{shift ctrl ADD}
Nov 11, 2011 7:51:14 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{shift ctrl SUBTRACT}
Nov 11, 2011 7:51:14 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{shift ctrl COMMA}
Nov 11, 2011 7:51:14 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{shift ctrl PERIOD}
Nov 11, 2011 7:51:14 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{shift ctrl SEMICOLON}
Nov 11, 2011 7:51:14 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{ctrl alt HOME}
Nov 11, 2011 7:51:14 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{ctrl alt PAGE_UP}
Nov 11, 2011 7:51:14 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Registering hotkey: HotKey{ctrl alt NUMPAD0}
Nov 11, 2011 7:52:02 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Received event for hotkey: HotKey{ctrl alt D}
HotKey{ctrl alt D}
Nov 11, 2011 7:52:02 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Reset hotkeys
Nov 11, 2011 7:52:03 AM com.tulskiy.keymaster.x11.X11Provider$1 run
INFO: Thread - stop listening

On Fri, Nov 11, 2011 at 1:15 AM, Denis Tulskiy <
[email protected]>wrote:

There should be no space after -D, and you need to use -jar instead of
-cp if you're running just a jar.

java -Djava.library.path=/usr/lib -jar JavaKeyTest.jar

On Fri, Nov 11, 2011 at 1:45 PM, scmurdock <
[email protected]>wrote:

I'm on a 32 bit OS. I tried the following command. The jar file has a
main
method specified when building from eclipse and it even tries to run
(hence
the original error). Yet after using the options specified I invariably
get
this:

$ java -D java.library.path=/usr/lib -cp JavaKeyTest.jar
Exception in thread "main" java.lang.NoClassDefFoundError:
java/library/path=/usr/lib
Caused by: java.lang.ClassNotFoundException: java.library.path=.usr.lib
at java.net.URLClassLoader$1.run(URLClassLoader.java:217)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:205)
at java.lang.ClassLoader.loadClass(ClassLoader.java:321)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294)
at java.lang.ClassLoader.loadClass(ClassLoader.java:266)
Could not find the main class: java.library.path=/usr/lib. Program will
exit.

On Thu, Nov 10, 2011 at 10:30 AM, Denis Tulskiy <
[email protected]>wrote:

Hi, Sean,

I don't think modifying these variables from code will work, try adding
these params to the java vm as:

java -Djava.library.path=/usr/lib -cp example.jar YourClass

Also, are you on a 64-bit OS? I'm using this library on a Ubuntu 11.10
32-bit and all works fine.


Reply to this email directly or view it on GitHub:
#3 (comment)


Reply to this email directly or view it on GitHub:
#3 (comment)


Best,
Denis Tulskiy


Reply to this email directly or view it on GitHub:
#3 (comment)

from jkeymaster.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.