Bug 387

Summary: OS X 10.5, cannot find "nativeOrder" method of "BufferFactory" class
Product: [JogAmp] Jogl Reporter: Sven Gothel <sgothel>
Component: macosxAssignee: Sven Gothel <sgothel>
Status: VERIFIED WORKSFORME    
Severity: enhancement    
Priority: P5    
Version: 1   
Hardware: pc_all   
OS: macosx   
Type: --- SCM Refs:
Workaround: ---

Description Sven Gothel 2010-03-24 08:04:18 CET


---- Reported by sgothel@jausoft.com 2010-03-22 12:47:23 -0400 ----




---- Reported by vonseg@kenai.com 2010-02-14 19:14:38 ----

The online jogl demos do not work on my machine.  I am running Mac OS X version 10.5, and Java 1.6.0_17.  When I try to launch the gears demo, I get this exception:

                java.lang.reflect.InvocationTargetException
                at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
                at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                at java.lang.reflect.Method.invoke(Method.java:597)
                at com.sun.javaws.Launcher.executeApplication(Launcher.java:1528)
                at com.sun.javaws.Launcher.executeMainClass(Launcher.java:1466)
                at com.sun.javaws.Launcher.doLaunchApp(Launcher.java:1277)
                at com.sun.javaws.Launcher.run(Launcher.java:117)
                at java.lang.Thread.run(Thread.java:637)
                Caused by: java.lang.NoSuchMethodError: com.sun.gluegen.runtime.BufferFactory.nativeOrder(Ljava/nio/ByteBuffer;)Ljava/nio/ByteBuffer;
                at com.sun.nativewindow.impl.jawt.JAWT.GetDrawingSurface(JAWT.java:54)
                at com.sun.nativewindow.impl.jawt.macosx.MacOSXJAWTWindow.lockSurface(MacOSXJAWTWindow.java:65)
                at com.sun.opengl.impl.GLDrawableImpl.lockSurface(GLDrawableImpl.java:130)
                at com.sun.opengl.impl.macosx.cgl.MacOSXCGLDrawable.setRealized(MacOSXCGLDrawable.java:89)
                at javax.media.opengl.awt.GLCanvas.addNotify(GLCanvas.java:413)
                at java.awt.Container.addNotify(Container.java:2622)
                at java.awt.Window.addNotify(Window.java:662)
                at java.awt.Frame.addNotify(Frame.java:470)
                at java.awt.Window.show(Window.java:858)
                at java.awt.Component.show(Component.java:1563)
                at java.awt.Component.setVisible(Component.java:1515)
                at java.awt.Window.setVisible(Window.java:841)
                at demos.gears.Gears.main(Gears.java:51)
                ... 9 more


                When I try to build jogl, I get similar errors:

                java.compile.javase:
                [javac] Compiling 49 source files to /jogl/src/jogl/build/nativewindow/classes
                [javac] /jogl/src/jogl/build/nativewindow/gensrc/classes/com/sun/nativewindow/impl/jawt/JAWT_DrawingSurface.java:58: cannot find symbol
                [javac] symbol  : method nativeOrder(java.nio.ByteBuffer)
                [javac] location: class com.sun.gluegen.runtime.BufferFactory
                [javac]     return JAWT_DrawingSurfaceInfo.create(BufferFactory.nativeOrder(_res));
                [javac]                                                        ^
                [javac] /jogl/src/jogl/build/nativewindow/gensrc/classes/com/sun/nativewindow/impl/jawt/JAWT.java:54: cannot find symbol
                [javac] symbol  : method nativeOrder(java.nio.ByteBuffer)
                [javac] location: class com.sun.gluegen.runtime.BufferFactory
                [javac]     return JAWT_DrawingSurface.create(BufferFactory.nativeOrder(_res));
                [javac]                                                    ^
                [javac] /jogl/src/jogl/build/nativewindow/gensrc/classes/com/sun/nativewindow/impl/x11/X11Lib.java:170: cannot find symbol
                [javac] symbol  : method nativeOrder(java.nio.ByteBuffer)
                [javac] location: class com.sun.gluegen.runtime.BufferFactory
                [javac]       BufferFactory.nativeOrder(_res);
                [javac]                    ^
                [javac] 3 errors


            For what it's worth, I have an older machine running OS X version 10.4, and it does not have any problems running the jogl demos.



---- Additional Comments From ansorre2@kenai.com 2010-03-17 23:54:52 ----

(In reply to comment #0)
                > ....
                > When I try to build jogl, I get similar errors:
                >
                > java.compile.javase:
                >     [javac] Compiling 49 source files to
                > /jogl/src/jogl/build/nativewindow/classes
                >     [javac]
                > /jogl/src/jogl/build/nativewindow/gensrc/classes/com/sun/nativewindow/impl/jawt/JAWT_DrawingSurface.java:58:
                > cannot find symbol
                >     [javac] symbol  : method nativeOrder(java.nio.ByteBuffer)
                >     [javac] location: class com.sun.gluegen.runtime.BufferFactory
                >     [javac]     return
                > JAWT_DrawingSurfaceInfo.create(BufferFactory.nativeOrder(_res));
                > ....
                > ....
                > ....

                I had exactly the same identical problem building JOGL on a Windows XP machine, then I discovered I had some old gluegen jar and dll in my jdk\jre\lib\ext directory. Deleting those old files totally solved all my problems and compilation was succesful.
                You say you are on Mac OS X, so check /Library/Java/Extensions for these old files and if you find them remove them and retry.
            Hope this helps.



--- Bug imported by sgothel@jausoft.com 2010-03-22 12:47 EDT  ---

This bug was previously known as _bug_ 2108 at http://kenai.com/bugzilla/show_bug.cgi?id=2108

The original reporter of this bug does not have
   an account here. Reassigning to the person who moved
   it here: sgothel@jausoft.com.
   Previous reporter was vonseg@kenai.com.
CC member ansorre2@kenai.com does not have an account here





--- Bug imported by sgothel@jausoft.com 2010-03-24 08:04 EDT  ---

This bug was previously known as _bug_ 12 at http://jogamp.org/bugzilla/show_bug.cgi?id=12
Comment 1 Sven Gothel 2011-02-25 23:32:13 CET
supported by now