Page 1 of 3 123 LastLast
Results 1 to 10 of 21

Thread: no jogl in java.library.path

  1. #1
    Senior Member
    Join Date
    Jun 2009
    Posts
    124

    Exclamation no jogl in java.library.path

    ok so I've got my file going.

    it compiles perfectly, builds perfectly, and runs perfectly. All within Netbeans.

    Everything works within netbeans.

    (I have -djava path in vm options, I have the libraries in the compile and jogl in the run properties)

    Once you build it gives the message

    To run this application from the command line without Ant, Try:
    Java -jar "c:\path\to\my\jar.jar"


    When I run this from command I get

    Exception in thread "AWT-EventQueue-0" java.lang.UnsatisfiedLinkError: No jogl in java.library.path

    Why does my program work within netbeans but won't run the .jar with the command prompt?

  2. #2

    Default

    Follow the JOGL installation instructions.

    Place the .dll files in your JAVA_HOME/jre/bin directory.
    Place the jars in your JAVA_HOME/jre/lib/ext directory.

    Everything 'should' work then.

  3. #3
    Super Moderator
    Join Date
    Nov 2006
    Location
    Mojave & Oxnard California
    Posts
    2,904

    Default

    It seems that the jogl developers should have made an installer/updater.

  4. #4
    WWJ Consultant patmurris's Avatar
    Join Date
    Jun 2005
    Location
    Saint-Paul de Vence, Alpes Maritimes, France
    Posts
    3,382

    Default

    Look at the build.xml, it contains a script for JOGL setup.
    However, this part is commented out right now i think, because of the transition to JOGL 2 for which we are not ready yet.
    My World Wind Java Blog & WW.net Plugins page

  5. #5
    World Wind Developer geodan's Avatar
    Join Date
    Aug 2005
    Location
    United States
    Posts
    357

    Default Same issue, Java hurts...

    Hey Guys,

    I'm having the same issue, and I'm sure it's something relatively easy. I'm just trying to get involved with WorldWind Java...but coming from .NET, it hurts. Was anyone able to resolve the 'no jogl found in library path' error?

    Any tips are greatly appreciated. I just want to be able to compile files and run them...

    thanks,
    Dan
    Last edited by geodan; 11-08-2010 at 09:10 PM.

  6. #6
    Senior Member
    Join Date
    Jun 2009
    Posts
    124

    Default

    it's been a while since I messed with this... however I no longer attempt to run it from the command prompt.

    I create a JNLP file which basically tells the java application where it's resources live, and then I have a folder with all the jogl resources included (.dlls and jars).

  7. #7
    Super Moderator
    Join Date
    Nov 2006
    Location
    Mojave & Oxnard California
    Posts
    2,904

    Default

    If you have the .dlls (only two required) in the directory as your app in Win it should work.

    In Linux, which does not automatically search the current dir:
    -Djava.library.path=.
    In Linux all the jogl files in the WWJ SDK are in the dir with the app, have not taken the time to see what can be omitted (.dll + ?).

    I often run/suggest a .bat file for the app/s in Win.
    I always use a .bash file in Linux (except tinkering on the command line)
    -Xmx512m -Dsun.java2d.noddraw=true

    You can run out of heap space with Java.

    edit: Note that in Linux if you make a link to your app and move/drag the link to the desktop your .bash starts in that dir. A line in the .bash should cd to the dir where your app is.

    cd /home/neil/WW
    java -Xmx512m -Dsun.java2d.noddraw=true -Djava.library.path=. -jar NLNww.jar
    read -p "end"
    Last edited by nlneilson; 11-08-2010 at 11:46 PM.

  8. #8
    World Wind Developer geodan's Avatar
    Join Date
    Aug 2005
    Location
    United States
    Posts
    357

    Default not yet

    well, i've tried just about every combination of putting files in different places...not yet working. I've taken a look at the JNLP files that NASA has on their demos page...tried to modify one of those and it seems like it might almost work...but...i get signing errors. As for JOGL, I assume that it's ok to reference it by URL like NASA does in their JNLP files.

    These are the reasons I've avoided JAVA for so long, just a pain to get apps working and distributed.

    any other dev tips that you might have are greatly appreciated.

    thanks,
    Dan

  9. #9
    World Wind Developer
    Join Date
    Sep 2010
    Location
    Santa Barbara, CA
    Posts
    327

    Default

    geodan: Can you explain how you're trying to run WorldWind? Is it from the command line? On what operating system?

    On Windows, a minimal WorldWind setup is:

    Code:
    C:\test>dir
    
     Directory of C:\test
    
    11/08/2010  03:02 PM    <DIR>          .
    11/08/2010  03:02 PM    <DIR>          ..
    11/08/2010  10:18 AM            20,480 gluegen-rt.dll
    11/08/2010  10:18 AM            18,416 gluegen-rt.jar
    11/08/2010  10:18 AM           315,392 jogl.dll
    11/08/2010  10:18 AM         1,126,403 jogl.jar
    11/08/2010  10:18 AM            20,480 jogl_awt.dll
    11/08/2010  10:18 AM           114,688 jogl_cg.dll
    11/08/2010  10:18 AM         6,279,828 worldwind.jar
    I can run the basic WorldWind demo by executing:

    Code:
    C:\test>java -jar worldwind.jar
    On Windows, Java looks in the current working directory for the native libraries. As nlneilson pointed out, this may not be the case on other systems. You can specify the native library directory with the -Djava.library.path flag, as in:

    Code:
    C:\test>java -Djava.library.path=. -jar worldwind.jar

  10. #10
    World Wind Developer geodan's Avatar
    Join Date
    Aug 2005
    Location
    United States
    Posts
    357

    Default what i'm trying to do

    What I'm trying to do is take one of the examples, i.e. the Measure Tool Usage example...and separate it into its own project...that I can start testing/modifying and so forth.

    Ideally, I'd be able to distribute something like the Measure Tool Usage example, on both Windows AND Mac.

    I followed the instructions on the wiki, and I can "right-click" on the examples and they run within NetBeans...but...if I try to set the Main Class as the Measure Tool Usage example, it will run within netbeans, but I can't get the JAR file to execute via command line...nor if I create a JNLP file, I get a variety of errors, mostly to do with "signing".

    These concepts are fairly new to me because I'm a .NET guy.



    (tomorrow is another day I guess)

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. What version of JOGL is this with WWJ 1.6??
    By naql in forum Development Help
    Replies: 2
    Last Post: 06-22-2009, 05:22 PM
  2. no jogl in path
    By cmaxwell in forum Development Help
    Replies: 6
    Last Post: 07-15-2008, 03:07 AM
  3. WWJ SDK to abstract JOGL to make a map server
    By mikequentel in forum Applications
    Replies: 0
    Last Post: 05-01-2008, 08:32 PM
  4. JOGL forum/Behavior of WWJ Applet in Browser
    By rogene in forum Development Help
    Replies: 1
    Last Post: 04-21-2008, 03:39 AM
  5. JOGL programming
    By adrianboimvaser in forum Development Help
    Replies: 7
    Last Post: 03-28-2008, 09:56 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •