tuonghuynh
Posts: 4
Joined: Thu Jan 04, 2007 11:43 pm

MAC OS

Hi,

I make the installer for MAC OS but got problem with native library, jogl libraries. Even I specify the JAVA_LIBRARY_PATH point to my native library it does not work.

key>java.library.path</key>
<string>$APP_PACKAGE/Contents/Resources/Java/cseo/JODAF1.X/native_libraries</string>

I read the jogl documents, it tell me to set DYLD_LIBRARY_PATH poin to my jogl lib. Could you please tell me how to set DYLD_LIBRARY_PATH is the MAC OS installer?

If you have experience with making MAC OS installer for application using jogl. Please give me some advices.

Thanks
gigi
Posts: 2103
Joined: Tue Apr 11, 2006 9:55 am
Contact: Website

Hi,

Please make sure that you use the JOGL MacOS binaries and that you include both "gluegen-rt.jar" and "jogl.jar" in the class path ("Java Products" page, "Settings" tab).

In the "Virtual Machine" tab specify the "java.library.path" parameter in the "Edit JVM Parameters" dialog and set its value to folder that contains the JOGL native MacOS libs (choose "Folder" from context menu of the "Value" field).

If you still encounter problems, launch the application from a terminal window, as follows:

1. Copy the archive to your desktop folder and extract it by double-clicking on it.

2. Open a terminal window and use the "cd" command as follows:

Code: Select all

cd ~/Desktop/[YourApplication]/[YourApplication.app]/Contents/MacOs
where [YourApplication] is the name of your Java Product. Use the "ls" command to see the contents of each directory.

3. Launch the "JavaApplicationStub" binary using the following command:

Code: Select all

./JavaApplicationStub
4. Post the stack trace displayed by the Java VM.

Best Regards,
Gigi
______________
Gheorghe Rada
Advanced Installer Team
http://www.advancedinstaller.com
tuonghuynh
Posts: 4
Joined: Thu Jan 04, 2007 11:43 pm

Hi Gigi,

Thanks for your replying. I still got an error as the following:

===== Tuesday, June 5, 2007 3:00:49 PM US/Mountain =====
Exception in thread "AWT-EventQueue-0" java.lang.UnsatisfiedLinkError: JAWT_GetAWT0
at net.java.games.jogl.impl.JAWTFactory.JAWT_GetAWT0(Native Method)
at net.java.games.jogl.impl.JAWTFactory.JAWT_GetAWT(JAWTFactory.java:37)
at net.java.games.jogl.impl.NativeLibLoader$1.run(NativeLibLoader.java:78)
at java.security.AccessController.doPrivileged(Native Method)
at net.java.games.jogl.impl.NativeLibLoader.load(NativeLibLoader.java:58)
at net.java.games.jogl.impl.GLContext.<clinit>(GLContext.java:50)
at net.java.games.jogl.impl.macosx.MacOSXGLContextFactory.createGLContext(MacOSXGLContextFactory.java:60)
at net.java.games.jogl.GLCanvas.<init>(GLCanvas.java:72)
at net.java.games.jogl.GLDrawableFactory.createGLCanvas(GLDrawableFactory.java:150)
at net.java.games.jogl.GLDrawableFactory.createGLCanvas(GLDrawableFactory.java:118)
at net.java.games.jogl.GLDrawableFactory.createGLCanvas(GLDrawableFactory.java:85)
at cseo.moldesign.client.view.ogl_pane.OGLWindow.<init>(OGLWindow.java:133)
at cseo.moldesign.client.Controller.setupViews(Controller.java:202)
at cseo.moldesign.client.Controller.<init>(Controller.java:181)
at cseo.moldesign.client.MolDesign.<init>(MolDesign.java:77)
at cseo.moldesign.client.LocalRequestBox.receiveRequest(LocalRequestBox.java:20)
at cseo.jodaf.client.JODAF.sendRequest(JODAF.java:1185)
at cseo.jodaf.client.JODAFRequestBox.sendRequest(JODAFRequestBox.java:156)
at cseo.jodaf.client.desktop.Desktop.launchApplication(Desktop.java:763)
at cseo.jodaf.client.desktop.view.VDesktop.mouseClicked(VDesktop.java:443)
at java.awt.Component.processMouseEvent(Component.java:5557)
at javax.swing.JComponent.processMouseEvent(JComponent.java:3126)
at java.awt.Component.processEvent(Component.java:5319)
at java.awt.Container.processEvent(Container.java:2010)
at java.awt.Component.dispatchEventImpl(Component.java:4021)
at java.awt.Container.dispatchEventImpl(Container.java:2068)
at java.awt.Component.dispatchEvent(Component.java:3869)
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4256)
at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3945)
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3866)
at java.awt.Container.dispatchEventImpl(Container.java:2054)
at java.awt.Window.dispatchEventImpl(Window.java:1774)
at java.awt.Component.dispatchEvent(Component.java:3869)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:463)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:269)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:190)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:184)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:176)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)

=============================
I put all jogl stuffs in the native_libraries folder. The content of info.plist is

<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE plist SYSTEM "file://localhost/System/Library/DTDs/PropertyList.dtd"><plist version="1.0"><dict><key>CFBundleDevelopmentRegion</key>

<string>en</string>

<key>CFBundleName</key>

<string>CSE-Online</string>

<key>CFBundleVersion</key>

<string>1.0.0</string>

<key>CFBundleShortVersionString</key>

<string>CSE-Online 1.0.0</string>

<key>CFBundleExecutable</key>

<string>JavaApplicationStub</string>

<key>CFBundlePackageType</key>

<string>APPL</string>

<key>CFBundleSignature</key>

<string>????</string>

<key>CFBundleGetInfoString</key>

<string>CSE-Online 1.0.0 © cseo, Inc, 2007</string>

<key>CFBundleIconFile</key>

<string>start.icns</string>

<key>LSMinimumSystemVersion</key>

<string>10.4.0</string>

<key>CFBundleAllowMixedLocalizations</key>

<true/>

<key>CFBundleInfoDictionaryVersion</key>

<string>6.0</string>

<key>CFBundleIdentifier</key>

<string>com.cseo.CSE-Online.CSE-Online</string>

<key>LSHasLocalizedDisplayName</key>

<true/>

<key>CFBundleDisplayName</key>

<string>CSE-Online</string>

<key>Java</key>

<dict><key>MainClass</key>

<string>cseo.jodaf.client.JODAF</string>

<key>ClassPath</key>

<string>$APP_PACKAGE/Contents/Resources/Java/cseo/JODAF/Jodaf_1.1.jar:$APP_PACKAGE/Contents/Resources/Java/cseo/JODAF1.X/native_libraries/</string>

<key>Properties</key>

<dict><key>java.library.path</key>

<string>$APP_PACKAGE/Contents/Resources/Java/cseo/JODAF1.X/native_libraries</string>

<key>javax.net.ssl.trustStore</key>

<string>$APP_PACKAGE/Contents/Resources/Java/cseo/JODAF/cseotrust</string>

<key>org.jboss.security.ignoreHttpsHost</key>

<string>true</string>

<key>user.home</key>

<string>$APP_PACKAGE/Contents/Resources/Java/</string>

</dict>

<key>VMOptions</key>

<string>-Xms64M -Xmx256M</string>

<key>JVMVersion</key>

<string>1.5*</string>

</dict>

</dict></plist>

Thanks,
Tuong
gigi
Posts: 2103
Joined: Tue Apr 11, 2006 9:55 am
Contact: Website

Hi Tuong,
<key>ClassPath</key>

<string>$APP_PACKAGE/Contents/Resources/Java/cseo/JODAF/Jodaf_1.1.jar:$APP_PACKAGE/Contents/Resources/Java/cseo/JODAF1.X/native_libraries/</string>
I notice that you don't include the jogl jar files in the "Class Path". So in "Java Products" page, "Settings" tab you need to and both "gluegen-rt.jar" and "jogl.jar" in the class path.

Regards,
Gigi
______________
Gheorghe Rada
Advanced Installer Team
http://www.advancedinstaller.com

Return to “Common Problems”