<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xmlns:thr="http://purl.org/syndication/thread/1.0">
	
	<id>tag:jogamp.762907.n3.nabble.com,2006:forum-784684</id>
	<title>Nabble - gluegen</title>
	<updated>2012-05-16T16:28:26Z</updated>
	<link rel="self" type="application/atom+xml" href="http://jogamp.762907.n3.nabble.com/gluegen-f784684.xml" />
	<link rel="alternate" type="text/html" href="http://forum.jogamp.org/gluegen-f784684.html" />
	<subtitle type="html">Everything related to GlueGen, the Java binding code generator.</subtitle>
	
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3911545</id>
		<title>Re: New to gluegen</title>
		<published>2012-04-15T00:46:54Z</published>
		<updated>2012-04-15T00:46:54Z</updated>
		<author>
			<name>gouessej</name>
		</author>
		<content type="html">
			Hi
&lt;br/&gt;&lt;br/&gt;There are programs that automatize the way of using JNA too like JNAerator. JNA is a bit slower than JNI. I know EFL, I used it once, I don't really understand why someone would create a Java binding for that :s
	&lt;div class=&quot;signature weak-color&quot;&gt;Julien Gouesse
&lt;br/&gt;&lt;a href=&quot;http://tuer.sourceforge.net&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://tuer.sourceforge.net&lt;/a&gt;&lt;br/&gt;&lt;a href=&quot;http://gouessej.wordpress.com&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://gouessej.wordpress.com&lt;/a&gt;&lt;/div&gt;
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/New-to-gluegen-tp3911287p3911545.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-3911287"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3911287</id>
		<title>New to gluegen</title>
		<published>2012-04-14T20:08:04Z</published>
		<updated>2012-04-14T20:08:04Z</updated>
		<author>
			<name>Daniel Fitzpatrick</name>
		</author>
		<content type="html">
			Cross-post: &lt;a href=&quot;http://stackoverflow.com/questions/10159201/fast-track-to-clojure-java-bindings-for-the-efl&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://stackoverflow.com/questions/10159201/fast-track-to-clojure-java-bindings-for-the-efl&lt;/a&gt;
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/New-to-gluegen-tp3911287.html" />
		
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3776028</id>
		<title>Creating Javaclasses for Structs</title>
		<published>2012-02-25T16:05:20Z</published>
		<updated>2012-02-25T16:05:20Z</updated>
		<author>
			<name>Cola_Colin</name>
		</author>
		<content type="html">
			Hi, 
&lt;br/&gt;in order to pass some structures into an opencl kernel I am trying to use gluegen, which works mostly.
&lt;br/&gt;&lt;br/&gt;However at the moment I cannot find a way to make gluegen create classes for unused structures, so I need dummy functions in the header, which is a bit annoying. Is there a way to force gluegen to create the accessors for certain structures ?
&lt;br/&gt;&lt;br/&gt;Help is appreciated :)
&lt;br/&gt;&lt;br/&gt;
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/Creating-Javaclasses-for-Structs-tp3776028.html" />
		
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3709819</id>
		<title>Re: gluegen bundle problem?</title>
		<published>2012-02-02T05:25:13Z</published>
		<updated>2012-02-02T05:25:13Z</updated>
		<author>
			<name>gouessej</name>
		</author>
		<content type="html">
			You're welcome. I did the same mistake some years ago. The RC6 will use a single JAR for all native libraries, it will avoid such confusions.
	&lt;div class=&quot;signature weak-color&quot;&gt;Julien Gouesse
&lt;br/&gt;&lt;a href=&quot;http://tuer.sourceforge.net&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://tuer.sourceforge.net&lt;/a&gt;&lt;br/&gt;&lt;a href=&quot;http://gouessej.wordpress.com&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://gouessej.wordpress.com&lt;/a&gt;&lt;/div&gt;
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/gluegen-bundle-problem-tp3694709p3709819.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-3704226"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3704226</id>
		<title>Re: gluegen bundle problem?</title>
		<published>2012-01-31T10:33:04Z</published>
		<updated>2012-01-31T10:33:04Z</updated>
		<author>
			<name>pixelpshr</name>
		</author>
		<content type="html">
			Thanks again! I've been doing some more reading about this, but I know there's plenty that I still don't know.
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/gluegen-bundle-problem-tp3694709p3704226.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-3704178"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3704178</id>
		<title>Re: gluegen bundle problem?</title>
		<published>2012-01-31T10:15:57Z</published>
		<updated>2012-01-31T10:15:57Z</updated>
		<author>
			<name>gouessej</name>
		</author>
		<content type="html">
			It's not weird as Intel and AMD 64 bits processors use the same architecture. The same advice applies in almost any Java library relying on native libraries.
	&lt;div class=&quot;signature weak-color&quot;&gt;Julien Gouesse
&lt;br/&gt;&lt;a href=&quot;http://tuer.sourceforge.net&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://tuer.sourceforge.net&lt;/a&gt;&lt;br/&gt;&lt;a href=&quot;http://gouessej.wordpress.com&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://gouessej.wordpress.com&lt;/a&gt;&lt;/div&gt;
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/gluegen-bundle-problem-tp3694709p3704178.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-3703511"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3703511</id>
		<title>Re: gluegen bundle problem?</title>
		<published>2012-01-31T06:32:34Z</published>
		<updated>2012-01-31T06:32:34Z</updated>
		<author>
			<name>pixelpshr</name>
		</author>
		<content type="html">
			That's weird, but ok. Does the same advice apply for the rest of the packages?
&lt;br/&gt;
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/gluegen-bundle-problem-tp3694709p3703511.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-3699678"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3699678</id>
		<title>Re: gluegen bundle problem?</title>
		<published>2012-01-30T02:53:42Z</published>
		<updated>2012-01-30T02:53:42Z</updated>
		<author>
			<name>gouessej</name>
		</author>
		<content type="html">
			Hi
&lt;br/&gt;&lt;br/&gt;If you're on a 64 bits machine under Windows, you should use gluegen-rt-natives-windows-amd64.jar (even for Intel 64 bits).
	&lt;div class=&quot;signature weak-color&quot;&gt;Julien Gouesse
&lt;br/&gt;&lt;a href=&quot;http://tuer.sourceforge.net&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://tuer.sourceforge.net&lt;/a&gt;&lt;br/&gt;&lt;a href=&quot;http://gouessej.wordpress.com&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://gouessej.wordpress.com&lt;/a&gt;&lt;/div&gt;
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/gluegen-bundle-problem-tp3694709p3699678.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-3694709"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3694709</id>
		<title>gluegen bundle problem?</title>
		<published>2012-01-27T14:10:01Z</published>
		<updated>2012-01-27T14:10:01Z</updated>
		<author>
			<name>pixelpshr</name>
		</author>
		<content type="html">
			Hi, I'm just getting started with JOGL and I've run into a problem right at the start.
&lt;br/&gt;&lt;br/&gt;I have downloaded the latest binaries from the web site, version 2.0 rc5 windows i586. After unpacking the archives I linked them into my simple test program and tried to run. It immediately dumped with the first message being:
&lt;br/&gt;&lt;br/&gt;java.io.FileNotFoundException: C:\...\Projects\JOGL\gluegen-2.0-b33-20111219-windows-i586\jar\gluegen-rt-natives-windows-amd64.jar (The system cannot find the file specified)
&lt;br/&gt;&lt;br/&gt;It looks like the gluegen windows-i586 jar file was constructed improperly and it is trying to load the gluegen-rt windows-amd64 libraries.
&lt;br/&gt;&lt;br/&gt;Can anyone tell me what is going on here?
&lt;br/&gt;&lt;br/&gt;Thanks,
&lt;br/&gt;Thom
&lt;br/&gt;
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/gluegen-bundle-problem-tp3694709.html" />
		
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3683555</id>
		<title>Re: Problems getting started with gluten</title>
		<published>2012-01-23T17:49:47Z</published>
		<updated>2012-01-23T17:49:47Z</updated>
		<author>
			<name>Wade Walker</name>
		</author>
		<content type="html">
			The &amp;quot;unexpected token&amp;quot; error is what ANTLR says when the file it's parsing doesn't match the grammar it's using. This could mean that the header file you're trying to create a JNI interface for may contain some feature of C that the GlueGen parser doesn't properly support.
&lt;br/&gt;&lt;br/&gt;My suggestion would be to make a copy of your input header file, then edit it to remove the &amp;quot;extern&amp;quot; keywords which seem to be causing the errors, and run GlueGen again. If the errors go away, examine the resulting JNI interface to see if it's correct. If so, we may need to extend the GlueGen grammar a bit.
&lt;br/&gt;&lt;br/&gt;
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/Problems-getting-started-with-gluten-tp3679814p3683555.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-3679866"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3680663</id>
		<title>Re: Problems getting started with gluten</title>
		<published>2012-01-22T16:34:21Z</published>
		<updated>2012-01-22T16:34:21Z</updated>
		<author>
			<name>Sven Gothel</name>
		</author>
		<content type="html">
			On Sunday, January 22, 2012 11:29:35 PM Jennifer Milburn [via jogamp] wrote:
&lt;div class='shrinkable-quote'&gt;&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; Thanks Wade, 
&lt;br/&gt;&amp;gt; &amp;nbsp; &amp;nbsp;I had ant-antlr.jar on the class path (i.e. in the same directory) but I
&lt;br/&gt;&amp;gt; guess it was looking for antlr.jar. Your suggestion helped and I was able to
&lt;br/&gt;&amp;gt; generate the source code for one of the examples! &amp;nbsp;It appears that I can
&lt;br/&gt;&amp;gt; generate the JNI code for simple examples now. &amp;nbsp;I just tried generating the
&lt;br/&gt;&amp;gt; JNI code for the actual header file I need to work with and got a variety of
&lt;br/&gt;&amp;gt; errors. &amp;nbsp;However, it's clear that the gluegen is at least attempting to
&lt;br/&gt;&amp;gt; generate the JNI code. 
&lt;br/&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp;I'm just trying to test the generation process on MacOS so I don't
&lt;br/&gt;&amp;gt; really expect this to work completely. &amp;nbsp;I'm going to generate different JNI
&lt;br/&gt;&amp;gt; classes for Windows and Linux using their respective header files (i.e.
&lt;br/&gt;&amp;gt; slightly different header for the two operating systems). &amp;nbsp;However, I am
&lt;br/&gt;&amp;gt; getting a large number of errors mostly related to ANTLR running into an
&lt;br/&gt;&amp;gt; unexpected token 
&lt;br/&gt;&amp;gt; &amp;quot;extern&amp;quot; in the header. &amp;nbsp;
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; ANTLR Parsing Error: line 122:4919: unexpected token: extern token
&lt;br/&gt;&amp;gt; name:&amp;quot;extern&amp;quot;
&lt;br/&gt;&amp;gt; line 122:4919: unexpected token: extern
&lt;br/&gt;&amp;gt; 	at com.jogamp.gluegen.cgram.GnuCParser.externalDef(GnuCParser.java:522)
&lt;br/&gt;&amp;gt; 	at com.jogamp.gluegen.cgram.GnuCParser.externalList(GnuCParser.java:258)
&lt;br/&gt;&amp;gt; 	at com.jogamp.gluegen.cgram.GnuCParser.translationUnit(GnuCParser.java:219)
&lt;br/&gt;&amp;gt; 	at com.jogamp.gluegen.GlueGen.run(GlueGen.java:131)
&lt;br/&gt;&amp;gt; 	at com.jogamp.gluegen.GlueGen.main(GlueGen.java:363)
&lt;br/&gt;&amp;gt; (note there are about 30 of these errors)
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; I'm also getting the following error that is a little more serious. &amp;nbsp;Is this
&lt;br/&gt;&amp;gt; related to a limitation of JNI for this kind of method (i.e. a callback
&lt;br/&gt;&amp;gt; reference?)
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; Exception in thread &amp;quot;main&amp;quot; java.lang.RuntimeException: Exception occurred
&lt;br/&gt;&amp;gt; while generating glue code.
&lt;br/&gt;&amp;gt; 	at com.jogamp.gluegen.GlueGen.run(GlueGen.java:304)
&lt;br/&gt;&amp;gt; 	at com.jogamp.gluegen.GlueGen.main(GlueGen.java:363)
&lt;br/&gt;&amp;gt; Caused by: java.lang.RuntimeException: Error while generating bindings for
&lt;br/&gt;&amp;gt; &amp;quot;int AT_RegisterFeatureCallback(AT_H Hndl, const AT_WC * &amp;nbsp;Feature, int
&lt;br/&gt;&amp;gt; (*EvCallback)(AT_H Hndl, const AT_WC * &amp;nbsp;Feature, void * &amp;nbsp;Context), void * 
&lt;br/&gt;&amp;gt; Context);&amp;quot;
&lt;br/&gt;&amp;gt; 	at
&lt;br/&gt;&amp;gt; com.jogamp.gluegen.JavaEmitter.generateMethodBindingEmitters(JavaEmitter.java:726)
&lt;br/&gt;&amp;gt; 	at com.jogamp.gluegen.JavaEmitter.emitFunctions(JavaEmitter.java:419)
&lt;br/&gt;&amp;gt; 	at com.jogamp.gluegen.GlueGen.run(GlueGen.java:297)
&lt;br/&gt;&amp;gt; 	... 1 more
&lt;br/&gt;&amp;gt; Caused by: java.lang.RuntimeException: Don't know how to convert
&lt;br/&gt;&amp;gt; pointer/array type &amp;quot;FeatureCallback&amp;quot;
&lt;br/&gt;&amp;gt; 	at com.jogamp.gluegen.JavaEmitter.typeToJavaType(JavaEmitter.java:1292)
&lt;br/&gt;&amp;gt; 	at com.jogamp.gluegen.JavaEmitter.bindFunction(JavaEmitter.java:1717)
&lt;br/&gt;&amp;gt; 	at
&lt;br/&gt;&amp;gt; com.jogamp.gluegen.JavaEmitter.generateMethodBindingEmitters(JavaEmitter.java:651)
&lt;br/&gt;&amp;gt; 	... 3 more
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; Any insight would be appreciated :) &amp;nbsp;I don't have any control over the
&lt;br/&gt;&amp;gt; header or the C interface. &amp;nbsp;I'm simply trying to create a java interface to
&lt;br/&gt;&amp;gt; the cameras drivers for Linux and Windows and the drivers are provided by
&lt;br/&gt;&amp;gt; the manufacturer. 
&lt;/div&gt;&lt;br/&gt;Without seeing your c-header input files
&lt;br/&gt;I am not able to determine the source of the error, 
&lt;br/&gt;ie whether they come from the input or GlueGen itself.
&lt;br/&gt;&lt;br/&gt;GlueGen itself includes test code and headers which are being parsed
&lt;br/&gt;and code generated for:
&lt;br/&gt;&amp;nbsp; src/junit/com/jogamp/gluegen/test/junit/generation/test1.h
&lt;br/&gt;&lt;br/&gt;The following class tests the generated signatures _and_ the proper data handling:
&lt;br/&gt;&amp;nbsp; src/junit/com/jogamp/gluegen/test/junit/generation/BaseClass.java
&lt;br/&gt;&lt;br/&gt;Even though they are pretty simple, they demonstrate how it should work.
&lt;br/&gt;&lt;br/&gt;In JOGL for example, you can see more elaborated use of GlueGen 
&lt;br/&gt;including dealing with API specific macros like GL_API .. etc.
&lt;br/&gt;&lt;br/&gt;Reading your error messages it is at least clear that not all macros are resolved,
&lt;br/&gt;eg. AT_H, AT_WC, Feature .. etc .. - but they all need to be resolved to have GlueGen
&lt;br/&gt;parse valid C headers.
&lt;br/&gt;&lt;br/&gt;One way is to include specific headers for the GlueGen processing
&lt;br/&gt;where you resolve them in a special way, or use the proper headers if this is possible.
&lt;br/&gt;You also could define types as opaque etc .. in the config files.
&lt;br/&gt;&lt;br/&gt;~Sven
&lt;br/&gt;&lt;br/&gt;&amp;gt; Sincerely,
&lt;br/&gt;&amp;gt; Jennifer Milburn 
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/Problems-getting-started-with-gluten-tp3679814p3680663.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-3680428"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3680428</id>
		<title>Re: Problems getting started with gluten</title>
		<published>2012-01-22T14:29:35Z</published>
		<updated>2012-01-22T14:29:35Z</updated>
		<author>
			<name>Jennifer Milburn</name>
		</author>
		<content type="html">
			Thanks Wade, 
&lt;br/&gt;&amp;nbsp; &amp;nbsp;I had ant-antlr.jar on the class path (i.e. in the same directory) but I guess it was looking for antlr.jar. Your suggestion helped and I was able to generate the source code for one of the examples! &amp;nbsp;It appears that I can generate the JNI code for simple examples now. &amp;nbsp;I just tried generating the JNI code for the actual header file I need to work with and got a variety of errors. &amp;nbsp;However, it's clear that the gluegen is at least attempting to generate the JNI code. 
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;I'm just trying to test the generation process on MacOS so I don't really expect this to work completely. &amp;nbsp;I'm going to generate different JNI classes for Windows and Linux using their respective header files (i.e. slightly different header for the two operating systems). &amp;nbsp;However, I am getting a large number of errors mostly related to ANTLR running into an unexpected token 
&lt;br/&gt;&amp;quot;extern&amp;quot; in the header. &amp;nbsp;
&lt;br/&gt;&lt;br/&gt;ANTLR Parsing Error: line 122:4919: unexpected token: extern token name:&amp;quot;extern&amp;quot;
&lt;br/&gt;line 122:4919: unexpected token: extern
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; at com.jogamp.gluegen.cgram.GnuCParser.externalDef(GnuCParser.java:522)
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; at com.jogamp.gluegen.cgram.GnuCParser.externalList(GnuCParser.java:258)
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; at com.jogamp.gluegen.cgram.GnuCParser.translationUnit(GnuCParser.java:219)
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; at com.jogamp.gluegen.GlueGen.run(GlueGen.java:131)
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; at com.jogamp.gluegen.GlueGen.main(GlueGen.java:363)
&lt;br/&gt;(note there are about 30 of these errors)
&lt;br/&gt;&lt;br/&gt;I'm also getting the following error that is a little more serious. &amp;nbsp;Is this related to a limitation of JNI for this kind of method (i.e. a callback reference?)
&lt;br/&gt;&lt;br/&gt;Exception in thread &amp;quot;main&amp;quot; java.lang.RuntimeException: Exception occurred while generating glue code.
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; at com.jogamp.gluegen.GlueGen.run(GlueGen.java:304)
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; at com.jogamp.gluegen.GlueGen.main(GlueGen.java:363)
&lt;br/&gt;Caused by: java.lang.RuntimeException: Error while generating bindings for &amp;quot;int AT_RegisterFeatureCallback(AT_H Hndl, const AT_WC * &amp;nbsp;Feature, int (*EvCallback)(AT_H Hndl, const AT_WC * &amp;nbsp;Feature, void * &amp;nbsp;Context), void * &amp;nbsp;Context);&amp;quot;
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; at com.jogamp.gluegen.JavaEmitter.generateMethodBindingEmitters(JavaEmitter.java:726)
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; at com.jogamp.gluegen.JavaEmitter.emitFunctions(JavaEmitter.java:419)
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; at com.jogamp.gluegen.GlueGen.run(GlueGen.java:297)
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; ... 1 more
&lt;br/&gt;Caused by: java.lang.RuntimeException: Don't know how to convert pointer/array type &amp;quot;FeatureCallback&amp;quot;
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; at com.jogamp.gluegen.JavaEmitter.typeToJavaType(JavaEmitter.java:1292)
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; at com.jogamp.gluegen.JavaEmitter.bindFunction(JavaEmitter.java:1717)
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; at com.jogamp.gluegen.JavaEmitter.generateMethodBindingEmitters(JavaEmitter.java:651)
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; ... 3 more
&lt;br/&gt;&lt;br/&gt;Any insight would be appreciated :) &amp;nbsp;I don't have any control over the header or the C interface. &amp;nbsp;I'm simply trying to create a java interface to the cameras drivers for Linux and Windows and the drivers are provided by the manufacturer. 
&lt;br/&gt;Sincerely,
&lt;br/&gt;Jennifer Milburn 
&lt;br/&gt;
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/Problems-getting-started-with-gluten-tp3679814p3680428.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-3679866"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3679866</id>
		<title>Re: Problems getting started with gluten</title>
		<published>2012-01-22T12:26:49Z</published>
		<updated>2012-01-22T12:26:49Z</updated>
		<author>
			<name>Wade Walker</name>
		</author>
		<content type="html">
			Hi Jennifer,
&lt;br/&gt;&lt;br/&gt;The antlr/RecognitionException dependency is on antlr.jar, which is in gluegen/make/lib. If you add that to your classpath, gluegen should be able to run correctly.
&lt;br/&gt;&lt;br/&gt;To build gluegen (which it doesn't seem like you want to do, but just in case), just follow the instructions at &lt;a href=&quot;http://jogamp.org/wiki/index.php/Building_JOGL_on_the_command_line&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://jogamp.org/wiki/index.php/Building_JOGL_on_the_command_line&lt;/a&gt;, but ignore the parts about the jogl project. You don't need the Android SDK to do this build -- the whole thing should complete on the command line with no external dependencies (other than Java, Ant, and Git).
&lt;br/&gt;&lt;br/&gt;
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/Problems-getting-started-with-gluten-tp3679814p3679866.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-3679814"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3679814</id>
		<title>Problems getting started with gluten</title>
		<published>2012-01-22T11:50:22Z</published>
		<updated>2012-01-22T11:50:22Z</updated>
		<author>
			<name>Jennifer Milburn</name>
		</author>
		<content type="html">
			I'm just getting started with gluegen and I'm running into several problems. (Probably fairly dumb ones). &amp;nbsp;I've downloaded the current version using git and tried to build it a couple of different ways.
&lt;br/&gt;(1) Using the Netbeans project I can build. However, the source code appears to have a whole set of unsatisfied dependencies mainly related to import of android (e.g. import android.*). I'd like to include the android jar in the class path so these error flags go away but I can't find a simple android.jar. &amp;nbsp;It appears that you need to install a complete android SDK and I'm only interested in including the classes that are needed to satisfy gluegen.
&lt;br/&gt;(2) I'm really not interested in building gluegen but simply using it to generate the JNI interface required to interface with a couple of different scientific cameras using their header files. &amp;nbsp;I've tried simply downloading the .7z file for the operating system (MacOS) and running gluengen from the jar file (i.e. java -jar gluegen -I /mypath/to/example) using one of the examples in the doc folder but I get the same error:
&lt;br/&gt;&lt;br/&gt;Exception in thread &amp;quot;main&amp;quot; java.lang.NoClassDefFoundError: antlr/RecognitionException
&lt;br/&gt;Caused by: java.lang.ClassNotFoundException: antlr.RecognitionException
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; at java.security.AccessController.doPrivileged(Native Method)
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
&lt;br/&gt;&lt;br/&gt;I have the ant-antlr.jar file in the same folder as the gluegen.jar file and I can't figure out what I'm doing wrong. 
&lt;br/&gt;Anyone have any clue as to what's wrong?
&lt;br/&gt;&lt;br/&gt;Sincerely,
&lt;br/&gt;Jennifer Milburn 
&lt;br/&gt;jwm@astro.caltech.edu
&lt;br/&gt;
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/Problems-getting-started-with-gluten-tp3679814.html" />
		
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3677251</id>
		<title>Re: GlueGen tries to load 64 bits libs on 64 bits machines using 32 bits JVM</title>
		<published>2012-01-20T20:08:05Z</published>
		<updated>2012-01-20T20:08:05Z</updated>
		<author>
			<name>Gene</name>
		</author>
		<content type="html">
			I ran into this back in JOGL 1 days building an installer to pick 32- or 64-bit DLLs. &amp;nbsp;After much research I wrote the following code which has worked well on thousands of machines to date. &amp;nbsp;The project is welcome to the code and algorithm.
&lt;br/&gt;&lt;br/&gt;public class DetectJVM {
&lt;br/&gt;&lt;br/&gt;&amp;nbsp; &amp;nbsp; // Add to this list any Java attribute that, if the key exists in global
&lt;br/&gt;&amp;nbsp; &amp;nbsp; // properties, the value contains a 64 if and only if we are running a
&lt;br/&gt;&amp;nbsp; &amp;nbsp; // 64-bit JVM, which therefore needs AMD64 format DLLs in Windows.
&lt;br/&gt;&amp;nbsp; &amp;nbsp; private static final String keys [] = {
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;quot;sun.arch.data.model&amp;quot;,
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;quot;com.ibm.vm.bitmode&amp;quot;,
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;quot;os.arch&amp;quot;,
&lt;br/&gt;&amp;nbsp; &amp;nbsp; };
&lt;br/&gt;&lt;br/&gt;&amp;nbsp; &amp;nbsp; public static void main (String [] args) {
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; boolean print = args.length &amp;gt; 0 &amp;&amp; &amp;quot;-print&amp;quot;.equals(args[0]);
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; for (String key : keys) {
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; String property = System.getProperty(key);
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; if (print) {
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; System.out.println(key + &amp;quot;=&amp;quot; + property);
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; if (property != null) {
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; int errCode = (property.indexOf(&amp;quot;64&amp;quot;) &amp;gt;= 0) ? 64 : 32;
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; if (print) {
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; System.out.println(&amp;quot;err code=&amp;quot; + errCode);
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; System.exit(errCode);
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }
&lt;br/&gt;&amp;nbsp; &amp;nbsp; }
&lt;br/&gt;}
&lt;br/&gt;
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/GlueGen-tries-to-load-64-bits-libs-on-64-bits-machines-using-32-bits-JVM-tp3610342p3677251.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-3610342"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3610342</id>
		<title>GlueGen tries to load 64 bits libs on 64 bits machines using 32 bits JVM</title>
		<published>2011-12-24T02:39:08Z</published>
		<updated>2011-12-24T02:39:08Z</updated>
		<author>
			<name>gouessej</name>
		</author>
		<content type="html">
			Hi
&lt;br/&gt;&lt;br/&gt;When jogamp.gluegen.UseTempJarCache is set to true (by default), GlueGen tries to extract native libraries from JARs. It uses the architecture of the machine to determine which one should be loaded.
&lt;br/&gt;&lt;br/&gt;However, when someone uses a 32 bits JVM on a 64 bits machine, GlueGen does not find the 32 bits libraries as Java Web Start retrieves only the 64 bits libraries. How can I solve this problem? Should Java Web Start use a single JAR containing all native libraries? Should GlueGen then load the native libraries by looking at the architecture of the JVM?
&lt;br/&gt;&lt;br/&gt;Someone tested my game and obtained this:
&lt;br/&gt;Detected from bootclasspath: C:\\Program Files (x86)\\Java\\jre7\\lib\deploy.jar
&lt;br/&gt;Dez 24, 2011 10:56:23 AM engine.integration.DesktopIntegration &amp;lt;init&amp;gt;&lt;br/&gt;Information: operating system: windows 7
&lt;br/&gt;Dez 24, 2011 10:56:23 AM engine.integration.DesktopIntegration &amp;lt;init&amp;gt;&lt;br/&gt;Information: operating system family: Windows
&lt;br/&gt;Dez 24, 2011 10:56:23 AM engine.integration.DesktopIntegration &amp;lt;init&amp;gt;&lt;br/&gt;Information: tries to create a temporary file to contain the WSH script...
&lt;br/&gt;Dez 24, 2011 10:56:23 AM engine.integration.DesktopIntegration &amp;lt;init&amp;gt;&lt;br/&gt;Information: temporary file C:\Users\EGONOL~1\AppData\Local\Temp\getDesktopFolder5195775719385520981.js successfully created
&lt;br/&gt;Dez 24, 2011 10:56:23 AM engine.integration.DesktopIntegration &amp;lt;init&amp;gt;&lt;br/&gt;Information: temporary file C:\Users\EGONOL~1\AppData\Local\Temp\getDesktopFolder5195775719385520981.js successfully filled
&lt;br/&gt;Dez 24, 2011 10:56:23 AM engine.integration.DesktopIntegration &amp;lt;init&amp;gt;&lt;br/&gt;Information: registry value used as a desktop path: C:\Users\EgonOlsen\Desktop
&lt;br/&gt;Dez 24, 2011 10:56:23 AM engine.integration.DesktopIntegration &amp;lt;init&amp;gt;&lt;br/&gt;Information: operating system supported. Desktop path: C:\Users\EgonOlsen\Desktop
&lt;br/&gt;&lt;br/&gt;Starting up SoundSystem...
&lt;br/&gt;Initializing JOAL
&lt;br/&gt;&amp;nbsp; &amp;nbsp; (The JOAL binding of OpenAL. &amp;nbsp;For more information, see &lt;a href=&quot;http://joal.dev.java.net/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://joal.dev.java.net/&lt;/a&gt;)
&lt;br/&gt;java.nio.channels.ClosedByInterruptException
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at java.nio.channels.spi.AbstractInterruptibleChannel.end(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at sun.nio.ch.FileChannelImpl.write(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at java.nio.channels.Channels.writeFullyImpl(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at java.nio.channels.Channels.writeFully(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at java.nio.channels.Channels.access$000(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at java.nio.channels.Channels$1.write(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at java.nio.file.Files.copy(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at java.nio.file.Files.copy(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at sun.net.www.protocol.jar.URLJarFile$1.run(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at sun.net.www.protocol.jar.URLJarFile$1.run(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at java.security.AccessController.doPrivileged(Native Method)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at sun.net.www.protocol.jar.URLJarFile.retrieve(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at sun.net.www.protocol.jar.URLJarFile.getJarFile(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at sun.net.www.protocol.jar.JarFileFactory.get(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at sun.net.www.protocol.jar.JarURLConnection.connect(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.sun.jnlp.JNLPCachedJarURLConnection.connect(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.sun.jnlp.JNLPCachedJarURLConnection.getJarFile(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.common.util.JarUtil.getJarFile(JarUtil.java:294)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.common.util.cache.TempJarCache.bootstrapNativeLib(TempJarCache.java:346)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.common.os.Platform$3.run(Platform.java:312)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at java.security.AccessController.doPrivileged(Native Method)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.common.os.Platform.loadGlueGenRTImpl(Platform.java:303)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.common.os.Platform.&amp;lt;clinit&amp;gt;(Platform.java:214)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.common.os.NativeLibrary.&amp;lt;clinit&amp;gt;(NativeLibrary.java:76)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.common.os.DynamicLibraryBundle.&amp;lt;clinit&amp;gt;(DynamicLibraryBundle.java:56)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at jogamp.openal.ALImpl$1.run(ALImpl.java:2250)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at java.security.AccessController.doPrivileged(Native Method)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at jogamp.openal.ALImpl.&amp;lt;clinit&amp;gt;(ALImpl.java:2247)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.openal.ALFactory.initialize(ALFactory.java:58)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.openal.ALFactory.getALC(ALFactory.java:92)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.openal.util.ALut.alutInit(ALut.java:66)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at paulscode.sound.libraries.LibraryJOAL.init(LibraryJOAL.java:154)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at paulscode.sound.SoundSystem.CommandNewLibrary(SoundSystem.java:1576)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at paulscode.sound.SoundSystem.CommandQueue(SoundSystem.java:2572)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at paulscode.sound.CommandThread.run(CommandThread.java:121)
&lt;br/&gt;Exception in thread &amp;quot;Thread-12&amp;quot; java.lang.ExceptionInInitializerError
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.common.os.NativeLibrary.&amp;lt;clinit&amp;gt;(NativeLibrary.java:76)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.common.os.DynamicLibraryBundle.&amp;lt;clinit&amp;gt;(DynamicLibraryBundle.java:56)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at jogamp.openal.ALImpl$1.run(ALImpl.java:2250)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at java.security.AccessController.doPrivileged(Native Method)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at jogamp.openal.ALImpl.&amp;lt;clinit&amp;gt;(ALImpl.java:2247)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.openal.ALFactory.initialize(ALFactory.java:58)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.openal.ALFactory.getALC(ALFactory.java:92)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.openal.util.ALut.alutInit(ALut.java:66)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at paulscode.sound.libraries.LibraryJOAL.init(LibraryJOAL.java:154)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at paulscode.sound.SoundSystem.CommandNewLibrary(SoundSystem.java:1576)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at paulscode.sound.SoundSystem.CommandQueue(SoundSystem.java:2572)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at paulscode.sound.CommandThread.run(CommandThread.java:121)
&lt;br/&gt;Caused by: java.lang.NullPointerException
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.common.os.NativeLibrary.isValidNativeLibraryName(NativeLibrary.java:259)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.common.util.cache.TempJarCache.findLibrary(TempJarCache.java:288)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.common.jvm.JNILibLoaderBase.loadLibraryInternal(JNILibLoaderBase.java:303)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.common.jvm.JNILibLoaderBase.access$000(JNILibLoaderBase.java:55)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.common.jvm.JNILibLoaderBase$DefaultAction.loadLibrary(JNILibLoaderBase.java:85)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.common.jvm.JNILibLoaderBase.loadLibrary(JNILibLoaderBase.java:215)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.common.os.DynamicLibraryBundle$GlueJNILibLoader.loadLibrary(DynamicLibraryBundle.java:365)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.common.os.Platform$3.run(Platform.java:317)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at java.security.AccessController.doPrivileged(Native Method)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.common.os.Platform.loadGlueGenRTImpl(Platform.java:303)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.jogamp.common.os.Platform.&amp;lt;clinit&amp;gt;(Platform.java:214)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;... 12 more
&lt;br/&gt;The initialization of the sound manager (based on JOAL) failed: paulscode.sound.SoundSystemException: SoundSystem did not load after 30 seconds.
&lt;br/&gt;&lt;br/&gt;Starting up SoundSystem...
&lt;br/&gt;Initializing Java Sound
&lt;br/&gt;&amp;nbsp; &amp;nbsp; (The Java Sound API. &amp;nbsp;For more information, see &lt;a href=&quot;http://java.sun.com/products/java-media/sound/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://java.sun.com/products/java-media/sound/&lt;/a&gt;)
&lt;br/&gt;JavaSound initialized.
&lt;br/&gt;&lt;br/&gt;java.lang.NoClassDefFoundError: Could not initialize class com.jogamp.common.os.Platform
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at javax.media.opengl.GLProfile.&amp;lt;clinit&amp;gt;(GLProfile.java:81)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.ardor3d.framework.jogl.JoglNewtWindow.&amp;lt;clinit&amp;gt;(JoglNewtWindow.java:37)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at engine.service.Ardor3DGameServiceProvider.&amp;lt;init&amp;gt;(Ardor3DGameServiceProvider.java:212)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at engine.service.Ardor3DGameServiceProvider.main(Ardor3DGameServiceProvider.java:159)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at java.lang.reflect.Method.invoke(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.sun.javaws.Launcher.executeApplication(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.sun.javaws.Launcher.executeMainClass(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.sun.javaws.Launcher.doLaunchApp(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at com.sun.javaws.Launcher.run(Unknown Source)
&lt;br/&gt;&amp;nbsp; &amp;nbsp;at java.lang.Thread.run(Unknown Source)
&lt;br/&gt;#### Java Web Start Error:
&lt;br/&gt;#### null
&lt;br/&gt;&lt;br/&gt;Edit.: the bitness of the JVM can be detected by using the property sun.arch.data.model.
	&lt;div class=&quot;signature weak-color&quot;&gt;Julien Gouesse
&lt;br/&gt;&lt;a href=&quot;http://tuer.sourceforge.net&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://tuer.sourceforge.net&lt;/a&gt;&lt;br/&gt;&lt;a href=&quot;http://gouessej.wordpress.com&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://gouessej.wordpress.com&lt;/a&gt;&lt;/div&gt;
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/GlueGen-tries-to-load-64-bits-libs-on-64-bits-machines-using-32-bits-JVM-tp3610342.html" />
		
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3554331</id>
		<title>Re: binding a C functions that allocates two chunks of memory and returns an integer</title>
		<published>2011-12-02T03:01:44Z</published>
		<updated>2011-12-02T03:01:44Z</updated>
		<author>
			<name>a001</name>
		</author>
		<content type="html">
			Sven, thank you very much. Your detailed answer was very useful.
&lt;br/&gt;&lt;br/&gt;There is still one more question, if you may.
&lt;br/&gt;&lt;br/&gt;I've mapped the foo_t to long, with Opaque long foo_t.
&lt;br/&gt;&lt;br/&gt;Now, &amp;nbsp;GlueGen provides:
&lt;br/&gt;&amp;nbsp; public int foo(PointerBuffer arg1, PointerBuffer arg2)
&lt;br/&gt;as the interface to:
&lt;br/&gt;&amp;nbsp; int foo(foo_t **a, foo_t **b);
&lt;br/&gt;&lt;br/&gt;&lt;br/&gt;What if I need to pass a (foo_t *) written by foo() to another API, say bar()?
&lt;br/&gt;&amp;nbsp; int bar(foo_t *a, int c);
&lt;br/&gt;&lt;br/&gt;Here, keeping foo_t opaque with long, a LongBuffer would be generated to the pointer to foo_t:
&lt;br/&gt;&amp;nbsp; public int bar(LongBuffer arg1, int arg1)
&lt;br/&gt;&lt;br/&gt;&lt;br/&gt;Looking at the PointerBuffer documentation, I've noticed the getBuffer() method, that could be used to return a ByteBuffer. In turn, a view of the ByteBuffer as LongBuffer can be created using the asLongBuffer() method.
&lt;br/&gt;&lt;br/&gt;Is there a better method to pass the PointerBuffer written by foo() as a LongBuffer to bar()?
&lt;br/&gt;&lt;br/&gt;Thank you very much.
&lt;br/&gt;&lt;br/&gt;Cheers,
&lt;br/&gt;a.
&lt;br/&gt;
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/binding-a-C-functions-that-allocates-two-chunks-of-memory-and-returns-an-integer-tp3547863p3554331.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-3548229"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3548229</id>
		<title>Re: binding a C functions that allocates two chunks of memory and returns an integer</title>
		<published>2011-11-30T05:08:26Z</published>
		<updated>2011-11-30T05:08:26Z</updated>
		<author>
			<name>Sven Gothel</name>
		</author>
		<content type="html">
			On Wednesday, November 30, 2011 11:23:46 AM a001 [via jogamp] wrote:
&lt;div class='shrinkable-quote'&gt;&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; Thanks for all the great work with JogAmp and GlueGen.
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; I have a C library (to be called from Java) and I would be happy to use
&lt;br/&gt;&amp;gt; GlueGen to automate the generation of the necessary Java and JNI code.
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; However, after looking to the GlueGen manual, I'm afraid I'm still missing
&lt;br/&gt;&amp;gt; something. I've noticed the examples you provide about how to manage ingoing
&lt;br/&gt;&amp;gt; and outgoing structs, array of structs, and array of pointers. They are
&lt;br/&gt;&amp;gt; great. 
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; Still, I have not understood how to bind API like the following:
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; &amp;nbsp; struct foo_s; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;/* forward decl */
&lt;br/&gt;&amp;gt; &amp;nbsp; typedef struct foo_s foo_t;
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; &amp;nbsp; int foo(foo_t **a, foo_t **b);
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; foo allocates two variables of type foo_t and places the addresses of
&lt;br/&gt;&amp;gt; allocated memory respectively in *a and *b. Returns zero on success, or one
&lt;br/&gt;&amp;gt; of the applicable error values on failure.
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; Please, can you tell me how to generate the glue code for this?
&lt;/div&gt;&lt;br/&gt;Since 'struct foo_s' is opaque, ie. a 'void *', it shall be opaque for GlueGen as well.
&lt;br/&gt;&lt;br/&gt;Your 2 arguments refer to a _writable_ pointer array of these opaque type,
&lt;br/&gt;hence the PointerType shall be generated.
&lt;br/&gt;&lt;br/&gt;We have similar tests in GlueGen's unit tests, and it works quite well, eg:
&lt;br/&gt;&lt;br/&gt;&amp;nbsp; &lt;a href=&quot;http://jogamp.org/git/?p=gluegen.git;a=blob;f=src/junit/com/jogamp/gluegen/test/junit/generation/test1.h;hb=HEAD&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://jogamp.org/git/?p=gluegen.git;a=blob;f=src/junit/com/jogamp/gluegen/test/junit/generation/test1.h;hb=HEAD&lt;/a&gt;&lt;br/&gt;&lt;br/&gt;&amp;nbsp; 30 typedef uint64_t foo; // similar to your 'struct foo' if opaque
&lt;br/&gt;&lt;br/&gt;&amp;nbsp; 44 /** Returns a copy of the passed array, each element incr by 1 */
&lt;br/&gt;&amp;nbsp; 45 MYAPI foo * MYAPIENTRY arrayTestFoo2(const foo * array );
&lt;br/&gt;&amp;nbsp; 46 
&lt;br/&gt;&amp;nbsp; 47 /** Increments each element of the passed array by 1 - IDENTITY */
&lt;br/&gt;&amp;nbsp; 48 MYAPI void MYAPIENTRY arrayTestFoo3(foo * array );
&lt;br/&gt;&amp;nbsp; 49 
&lt;br/&gt;&amp;nbsp; 50 /** Returns a array-array of the passed array, split at ARRAY size - IDENTITY! */
&lt;br/&gt;&amp;nbsp; 51 MYAPI foo * * MYAPIENTRY arrayTestFoo3ArrayToPtrPtr(const foo * array);
&lt;br/&gt;&amp;nbsp; 52 
&lt;br/&gt;&amp;nbsp; 53 /** Fills dest array ptr of ARRAY size with arrays (allocs) and copies content of src to it - COPY! */
&lt;br/&gt;&amp;nbsp; 54 MYAPI void MYAPIENTRY arrayTestFoo3CopyPtrPtrA(foo * * dest, const foo * * src);
&lt;br/&gt;&lt;br/&gt;A 'mapped' structure w/ an anonymous / opaque type here:
&lt;br/&gt;&amp;nbsp; &lt;a href=&quot;http://jogamp.org/git/?p=gluegen.git;a=blob;f=src/junit/com/jogamp/gluegen/test/junit/generation/test1.h;hb=HEAD#l132&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://jogamp.org/git/?p=gluegen.git;a=blob;f=src/junit/com/jogamp/gluegen/test/junit/generation/test1.h;hb=HEAD#l132&lt;/a&gt;&lt;br/&gt;&lt;br/&gt;The configuration here:
&lt;br/&gt;&amp;nbsp;Dynamic (function lookup, library loading at runtime) - RECOMMENDED:
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &lt;a href=&quot;http://jogamp.org/git/?p=gluegen.git;a=blob;f=src/junit/com/jogamp/gluegen/test/junit/generation/test1p2-gluegen.cfg;hb=HEAD&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://jogamp.org/git/?p=gluegen.git;a=blob;f=src/junit/com/jogamp/gluegen/test/junit/generation/test1p2-gluegen.cfg;hb=HEAD&lt;/a&gt;&lt;br/&gt;&amp;nbsp;Static:
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &lt;a href=&quot;http://jogamp.org/git/?p=gluegen.git;a=blob;f=src/junit/com/jogamp/gluegen/test/junit/generation/test1p1-gluegen.cfg;hb=HEAD&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://jogamp.org/git/?p=gluegen.git;a=blob;f=src/junit/com/jogamp/gluegen/test/junit/generation/test1p1-gluegen.cfg;hb=HEAD&lt;/a&gt;&lt;br/&gt;&amp;nbsp;Base:
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &lt;a href=&quot;http://jogamp.org/git/?p=gluegen.git;a=blob;f=src/junit/com/jogamp/gluegen/test/junit/generation/test1-common.cfg;hb=HEAD&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://jogamp.org/git/?p=gluegen.git;a=blob;f=src/junit/com/jogamp/gluegen/test/junit/generation/test1-common.cfg;hb=HEAD&lt;/a&gt;&lt;br/&gt;&lt;br/&gt;Note the return size definition in test1-common.cfg:
&lt;br/&gt;&amp;nbsp; 11 ReturnValueCapacity arrayTestFoo2 ARRAY_SIZE * sizeof(foo)
&lt;br/&gt;&amp;nbsp; 12 ReturnValueCapacity arrayTestFoo3ArrayToPtrPtr ARRAY_SIZE * sizeof(foo *)
&lt;br/&gt;&amp;nbsp; 13 ReturnValueCapacity arrayTestFoo3PtrPtr ARRAY_SIZE * sizeof(foo *)
&lt;br/&gt;&amp;nbsp; 14 ReturnValueCapacity typeTestAnonPointer ARRAY_SIZE * sizeof(MYAPIConfig)
&lt;br/&gt;&lt;br/&gt;GlueGen generates:
&lt;br/&gt;&lt;br/&gt;&amp;nbsp; /** Interface to C language function: &amp;lt;br&amp;gt; &amp;lt;code&amp;gt; foo * &amp;nbsp;arrayTestFoo2(const foo * &amp;nbsp;array); &amp;lt;/code&amp;gt; &amp;nbsp; &amp;nbsp;*/
&lt;br/&gt;&amp;nbsp; public LongBuffer arrayTestFoo2(LongBuffer array);
&lt;br/&gt;&lt;br/&gt;&amp;nbsp; /** Interface to C language function: &amp;lt;br&amp;gt; &amp;lt;code&amp;gt; foo * &amp;nbsp;arrayTestFoo2(const foo * &amp;nbsp;array); &amp;lt;/code&amp;gt; &amp;nbsp; &amp;nbsp;*/
&lt;br/&gt;&amp;nbsp; public LongBuffer arrayTestFoo2(long[] array, int array_offset);
&lt;br/&gt;&lt;br/&gt;&amp;nbsp; /** Interface to C language function: &amp;lt;br&amp;gt; &amp;lt;code&amp;gt; void arrayTestFoo3(foo * &amp;nbsp;array); &amp;lt;/code&amp;gt; &amp;nbsp; &amp;nbsp;*/
&lt;br/&gt;&amp;nbsp; public void arrayTestFoo3(LongBuffer array);
&lt;br/&gt;&lt;br/&gt;&amp;nbsp; /** Interface to C language function: &amp;lt;br&amp;gt; &amp;lt;code&amp;gt; void arrayTestFoo3(foo * &amp;nbsp;array); &amp;lt;/code&amp;gt; &amp;nbsp; &amp;nbsp;*/
&lt;br/&gt;&amp;nbsp; public void arrayTestFoo3(long[] array, int array_offset);
&lt;br/&gt;&lt;br/&gt;&amp;nbsp; /** Interface to C language function: &amp;lt;br&amp;gt; &amp;lt;code&amp;gt; foo * &amp;nbsp;* &amp;nbsp;arrayTestFoo3ArrayToPtrPtr(const foo * &amp;nbsp;array); &amp;lt;/code&amp;gt; &amp;nbsp; &amp;nbsp;*/
&lt;br/&gt;&amp;nbsp; public PointerBuffer arrayTestFoo3ArrayToPtrPtr(LongBuffer array);
&lt;br/&gt;&lt;br/&gt;&amp;nbsp; /** Interface to C language function: &amp;lt;br&amp;gt; &amp;lt;code&amp;gt; foo * &amp;nbsp;* &amp;nbsp;arrayTestFoo3ArrayToPtrPtr(const foo * &amp;nbsp;array); &amp;lt;/code&amp;gt; &amp;nbsp; &amp;nbsp;*/
&lt;br/&gt;&amp;nbsp; public PointerBuffer arrayTestFoo3ArrayToPtrPtr(long[] array, int array_offset);
&lt;br/&gt;&lt;br/&gt;&amp;nbsp; /** Interface to C language function: &amp;lt;br&amp;gt; &amp;lt;code&amp;gt; void arrayTestFoo3CopyPtrPtrA(foo * &amp;nbsp;* &amp;nbsp;dest, const foo * &amp;nbsp;* &amp;nbsp;src); &amp;lt;/code&amp;gt; &amp;nbsp; &amp;nbsp;*/
&lt;br/&gt;&amp;nbsp; public void arrayTestFoo3CopyPtrPtrA(PointerBuffer dest, PointerBuffer src);
&lt;br/&gt;&lt;br/&gt;&amp;nbsp; /** Interface to C language function: &amp;lt;br&amp;gt; &amp;lt;code&amp;gt; foo * &amp;nbsp;* &amp;nbsp;arrayTestFoo3PtrPtr(foo * &amp;nbsp;* &amp;nbsp;array); &amp;lt;/code&amp;gt; &amp;nbsp; &amp;nbsp;*/
&lt;br/&gt;&amp;nbsp; public PointerBuffer arrayTestFoo3PtrPtr(PointerBuffer array);
&lt;br/&gt;&lt;br/&gt;The tests for above bindings is here:
&lt;br/&gt;&amp;nbsp; &lt;a href=&quot;http://jogamp.org/git/?p=gluegen.git;a=blob;f=src/junit/com/jogamp/gluegen/test/junit/generation/BaseClass.java;hb=HEAD#l271&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://jogamp.org/git/?p=gluegen.git;a=blob;f=src/junit/com/jogamp/gluegen/test/junit/generation/BaseClass.java;hb=HEAD#l271&lt;/a&gt;&lt;br/&gt;&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; In the examples you provide I've noticed that all functions allocating
&lt;br/&gt;&amp;gt; memory return a pointer to some static storage and how the
&lt;br/&gt;&amp;gt; ReturnValueCapacity directive is used to specify the size of the returned
&lt;br/&gt;&amp;gt; memory.
&lt;br/&gt;&lt;br/&gt;Not 'static storage' it's all dynamic.
&lt;br/&gt;The ReturnValueCapacity is described above .. see configuration.
&lt;br/&gt;&lt;br/&gt;Let's see the Java impl .. :
&lt;br/&gt;&lt;br/&gt;&amp;nbsp; /** Entry point (through function pointer) to C language function: &amp;lt;br&amp;gt; &amp;lt;code&amp;gt; foo * &amp;nbsp;* &amp;nbsp;arrayTestFoo3ArrayToPtrPtr(const foo * &amp;nbsp;array); &amp;lt;/code&amp;gt; &amp;nbsp; &amp;nbsp;*/
&lt;br/&gt;&amp;nbsp; public PointerBuffer arrayTestFoo3ArrayToPtrPtr(long[] array, int array_offset) &amp;nbsp;{
&lt;br/&gt;&amp;nbsp; &amp;nbsp; // REMOVED CHECKS ..
&lt;br/&gt;&lt;br/&gt;&amp;nbsp; &amp;nbsp; ByteBuffer _res;
&lt;br/&gt;&amp;nbsp; &amp;nbsp; _res = dispatch_arrayTestFoo3ArrayToPtrPtr1(array, Buffers.SIZEOF_LONG * array_offset, false, __addr_);
&lt;br/&gt;&amp;nbsp; &amp;nbsp; if (_res == null) return null;
&lt;br/&gt;&amp;nbsp; &amp;nbsp; Buffers.nativeOrder(_res);
&lt;br/&gt;&amp;nbsp; &amp;nbsp; return PointerBuffer.wrap(_res);
&lt;br/&gt;&amp;nbsp; }
&lt;br/&gt;&lt;br/&gt;The native method returns the nio Buffer like this:
&lt;br/&gt;&amp;nbsp; return (*env)-&amp;gt;NewDirectByteBuffer(env, _res, ARRAY_SIZE * sizeof(foo *));
&lt;br/&gt;&lt;br/&gt;I hope this elaboration helps a little bit and these unit tests make things a bit more clear.
&lt;br/&gt;&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; What if we need to allocate two chunks of memory and return an integer? Do
&lt;br/&gt;&amp;gt; we need to hand-write some glue code?
&lt;br/&gt;&lt;br/&gt;Please provide a proper example, like the unit tests with C header and some API documentation.
&lt;br/&gt;Also don't forget to use 'const' whenever you can, to remove the 'write-back' codegen.
&lt;br/&gt;&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; Thanks again for GlueGen and I'm looking forward to using it in this
&lt;br/&gt;&amp;gt; project.
&lt;br/&gt;&lt;br/&gt;You are very welcome.
&lt;br/&gt;&lt;br/&gt;~Sven
&lt;br/&gt;&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; Cheers,
&lt;br/&gt;&amp;gt; a.
&lt;br/&gt;
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/binding-a-C-functions-that-allocates-two-chunks-of-memory-and-returns-an-integer-tp3547863p3548229.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-3547863"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3547863</id>
		<title>binding a C functions that allocates two chunks of memory and returns an integer</title>
		<published>2011-11-30T02:23:46Z</published>
		<updated>2011-11-30T02:23:46Z</updated>
		<author>
			<name>a001</name>
		</author>
		<content type="html">
			Thanks for all the great work with JogAmp and GlueGen.
&lt;br/&gt;&lt;br/&gt;I have a C library (to be called from Java) and I would be happy to use GlueGen to automate the generation of the necessary Java and JNI code.
&lt;br/&gt;&lt;br/&gt;However, after looking to the GlueGen manual, I'm afraid I'm still missing something. I've noticed the examples you provide about how to manage ingoing and outgoing structs, array of structs, and array of pointers. They are great. 
&lt;br/&gt;&lt;br/&gt;Still, I have not understood how to bind API like the following:
&lt;br/&gt;&lt;br/&gt;&amp;nbsp; struct foo_s; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;/* forward decl */
&lt;br/&gt;&amp;nbsp; typedef struct foo_s foo_t;
&lt;br/&gt;&lt;br/&gt;&amp;nbsp; int foo(foo_t **a, foo_t **b);
&lt;br/&gt;&lt;br/&gt;foo allocates two variables of type foo_t and places the addresses of allocated memory respectively in *a and *b. Returns zero on success, or one of the applicable error values on failure.
&lt;br/&gt;&lt;br/&gt;Please, can you tell me how to generate the glue code for this?
&lt;br/&gt;&lt;br/&gt;In the examples you provide I've noticed that all functions allocating memory return a pointer to some static storage and how the ReturnValueCapacity directive is used to specify the size of the returned memory.
&lt;br/&gt;&lt;br/&gt;What if we need to allocate two chunks of memory and return an integer? Do we need to hand-write some glue code?
&lt;br/&gt;&lt;br/&gt;Thanks again for GlueGen and I'm looking forward to using it in this project.
&lt;br/&gt;&lt;br/&gt;Cheers,
&lt;br/&gt;a.
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/binding-a-C-functions-that-allocates-two-chunks-of-memory-and-returns-an-integer-tp3547863.html" />
		
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3447470</id>
		<title>Re: Incompatible MachineDescriptions on MacBook Air</title>
		<published>2011-10-24T01:32:25Z</published>
		<updated>2011-10-24T01:32:25Z</updated>
		<author>
			<name>Sven Gothel</name>
		</author>
		<content type="html">
			On Sunday, October 23, 2011 11:02:39 PM Matthias Reitinger [via jogamp] wrote:
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; Hello there,
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; we are using JOGL 2.0-rc3 in one of our projects. Lately a client told us
&lt;br/&gt;&amp;gt; that our program won't start on his MacBook Air. The JVM shows the following
&lt;br/&gt;&amp;gt; stack trace/error message:
&lt;br/&gt;&lt;br/&gt;&amp;lt;snip/&amp;gt;
&lt;br/&gt;&lt;div class='shrinkable-quote'&gt;&lt;br/&gt;&amp;gt; Caused by: java.lang.RuntimeException: Incompatible MachineDescriptions:
&lt;br/&gt;&amp;gt; Static MachineDescriptionStatic: X86_32_UNIX(1): MachineDescription:
&lt;br/&gt;&amp;gt; runtimeValidated false, littleEndian true, 32Bit true, primitive size /
&lt;br/&gt;&amp;gt; alignment:
&lt;br/&gt;&amp;gt; &amp;nbsp;int8 &amp;nbsp; &amp;nbsp;1 / 1, int16 &amp;nbsp; 2 / 2
&lt;br/&gt;&amp;gt; &amp;nbsp;int &amp;nbsp; &amp;nbsp; 4 / 4, long &amp;nbsp; &amp;nbsp;4 / 4
&lt;br/&gt;&amp;gt; &amp;nbsp;int32 &amp;nbsp; 4 / 4, int64 &amp;nbsp; 8 / 4
&lt;br/&gt;&amp;gt; &amp;nbsp;float &amp;nbsp; 4 / 4, double &amp;nbsp;8 / 4, ldouble 12 / 4
&lt;br/&gt;&amp;gt; &amp;nbsp;pointer 4 / 4, page &amp;nbsp; &amp;nbsp;4096
&lt;br/&gt;&amp;gt; Runtime MachineDescription: runtimeValidated true, littleEndian true, 32Bit
&lt;br/&gt;&amp;gt; true, primitive size / alignment:
&lt;br/&gt;&amp;gt; &amp;nbsp;int8 &amp;nbsp; &amp;nbsp;1 / 1, int16 &amp;nbsp; 2 / 2
&lt;br/&gt;&amp;gt; &amp;nbsp;int &amp;nbsp; &amp;nbsp; 4 / 4, long &amp;nbsp; &amp;nbsp;4 / 4
&lt;br/&gt;&amp;gt; &amp;nbsp;int32 &amp;nbsp; 4 / 4, int64 &amp;nbsp; 8 / 4
&lt;br/&gt;&amp;gt; &amp;nbsp;float &amp;nbsp; 4 / 4, double &amp;nbsp;8 / 4, ldouble 16 / 16
&lt;br/&gt;&amp;gt; &amp;nbsp;pointer 4 / 4, page &amp;nbsp; &amp;nbsp;4096
&lt;br/&gt;&amp;gt; at com.jogamp.common.os.Platform.&amp;lt;clinit&amp;gt;(Platform.java:193)
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; The installed JVM version is 1.6.0_26. Anyone know how to fix this?
&lt;/div&gt;&lt;br/&gt;It's pretty interesting that OSX has diff. double type size/alignment for 'long double'.
&lt;br/&gt;I have checked their website and indeed, they have a note on this behavior for gcc &amp;gt;= 4.0.
&lt;br/&gt;&lt;br/&gt;I have updated the static MachineDescription in this regard (impacts code generation!)
&lt;br/&gt;&amp;nbsp; &lt;a href=&quot;http://jogamp.org/git/?p=gluegen.git;a=commitdiff;h=0bafac07b61f10c1a24e8c052937607bbfcb39ec&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://jogamp.org/git/?p=gluegen.git;a=commitdiff;h=0bafac07b61f10c1a24e8c052937607bbfcb39ec&lt;/a&gt;&lt;br/&gt;&amp;nbsp; &lt;a href=&quot;http://jogamp.org/git/?p=gluegen.git;a=commit;h=a19f98767da194ba468f53f56c2dcdb9d1d34ac8&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://jogamp.org/git/?p=gluegen.git;a=commit;h=a19f98767da194ba468f53f56c2dcdb9d1d34ac8&lt;/a&gt;&lt;br/&gt;&lt;br/&gt;Autobuild/test is already running.
&lt;br/&gt;&lt;br/&gt;Thank you Matthias.
&lt;br/&gt;&lt;br/&gt;~Sven
&lt;br/&gt;&lt;br/&gt;
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/Incompatible-MachineDescriptions-on-MacBook-Air-tp3446387p3447470.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-3446387"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3446387</id>
		<title>Incompatible MachineDescriptions on MacBook Air</title>
		<published>2011-10-23T14:02:38Z</published>
		<updated>2011-10-23T14:02:38Z</updated>
		<author>
			<name>Matthias Reitinger</name>
		</author>
		<content type="html">
			Hello there,
&lt;br/&gt;&lt;br/&gt;we are using JOGL 2.0-rc3 in one of our projects. Lately a client told us that our program won't start on his MacBook Air. The JVM shows the following stack trace/error message:
&lt;br/&gt;&lt;br/&gt;java.lang.ExceptionInInitializerError
&lt;br/&gt;at javax.media.nativewindow.NativeWindowFactory._getNativeWindowingType(NativeWindowFactory.java:105)
&lt;br/&gt;at javax.media.nativewindow.NativeWindowFactory.initSingleton(NativeWindowFactory.java:181)
&lt;br/&gt;at javax.media.opengl.GLProfile.initProfilesForDefaultDevices(GLProfile.java:1168)
&lt;br/&gt;at javax.media.opengl.GLProfile.access$000(GLProfile.java:71)
&lt;br/&gt;at javax.media.opengl.GLProfile$1.run(GLProfile.java:112)
&lt;br/&gt;at java.security.AccessController.doPrivileged(Native Method)
&lt;br/&gt;at javax.media.opengl.GLProfile.initSingleton(GLProfile.java:110)
&lt;br/&gt;[...our code...]
&lt;br/&gt;at java.lang.Thread.run(Thread.java:680)
&lt;br/&gt;Caused by: java.lang.RuntimeException: Incompatible MachineDescriptions:
&lt;br/&gt;Static MachineDescriptionStatic: X86_32_UNIX(1): MachineDescription: runtimeValidated false, littleEndian true, 32Bit true, primitive size / alignment:
&lt;br/&gt;&amp;nbsp;int8 &amp;nbsp; &amp;nbsp;1 / 1, int16 &amp;nbsp; 2 / 2
&lt;br/&gt;&amp;nbsp;int &amp;nbsp; &amp;nbsp; 4 / 4, long &amp;nbsp; &amp;nbsp;4 / 4
&lt;br/&gt;&amp;nbsp;int32 &amp;nbsp; 4 / 4, int64 &amp;nbsp; 8 / 4
&lt;br/&gt;&amp;nbsp;float &amp;nbsp; 4 / 4, double &amp;nbsp;8 / 4, ldouble 12 / 4
&lt;br/&gt;&amp;nbsp;pointer 4 / 4, page &amp;nbsp; &amp;nbsp;4096
&lt;br/&gt;Runtime MachineDescription: runtimeValidated true, littleEndian true, 32Bit true, primitive size / alignment:
&lt;br/&gt;&amp;nbsp;int8 &amp;nbsp; &amp;nbsp;1 / 1, int16 &amp;nbsp; 2 / 2
&lt;br/&gt;&amp;nbsp;int &amp;nbsp; &amp;nbsp; 4 / 4, long &amp;nbsp; &amp;nbsp;4 / 4
&lt;br/&gt;&amp;nbsp;int32 &amp;nbsp; 4 / 4, int64 &amp;nbsp; 8 / 4
&lt;br/&gt;&amp;nbsp;float &amp;nbsp; 4 / 4, double &amp;nbsp;8 / 4, ldouble 16 / 16
&lt;br/&gt;&amp;nbsp;pointer 4 / 4, page &amp;nbsp; &amp;nbsp;4096
&lt;br/&gt;at com.jogamp.common.os.Platform.&amp;lt;clinit&amp;gt;(Platform.java:193)
&lt;br/&gt;&lt;br/&gt;The installed JVM version is 1.6.0_26. Anyone know how to fix this?
&lt;br/&gt;&lt;br/&gt;Thanks,
&lt;br/&gt;Matthias
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/Incompatible-MachineDescriptions-on-MacBook-Air-tp3446387.html" />
		
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3087477</id>
		<title>Re: __stdcall not recognized</title>
		<published>2011-06-20T11:24:49Z</published>
		<updated>2011-06-20T11:24:49Z</updated>
		<author>
			<name>Dino Puller</name>
		</author>
		<content type="html">
			&amp;gt;well, actually we .. and khronos headers, and usually all others,
&lt;br/&gt;&amp;gt;use macro definitions to get around this non std qualifier. 
&lt;br/&gt;It's seems easier to do but i didn't understand how. I can create a stub header file in which gluegen can see the macro definition, but that keyword is needed into the generated native code. How can i instruct gluegen to use that keyword?
&lt;br/&gt;&lt;br/&gt;tnx,
&lt;br/&gt;&amp;nbsp; &amp;nbsp;Dino
&lt;br/&gt;
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/stdcall-not-recognized-tp3079928p3087477.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-3082244"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3082244</id>
		<title>Re: __stdcall not recognized</title>
		<published>2011-06-19T02:31:55Z</published>
		<updated>2011-06-19T02:31:55Z</updated>
		<author>
			<name>Sven Gothel</name>
		</author>
		<content type="html">
			On Saturday, June 18, 2011 11:04:23 PM Wade Walker [via jogamp] wrote:
&lt;div class='shrinkable-quote'&gt;&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; Hi Dino,
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; It looks like you might have to modify gluegen's C grammar slightly to make
&lt;br/&gt;&amp;gt; this work. If you check out the source and look in
&lt;br/&gt;&amp;gt; gluegen/src/java/com/jogamp/gluegen/cgram, you can see the ANTLR grammar
&lt;br/&gt;&amp;gt; files there (the *.g files). Inside HeaderParser.g and StdCParser.g, you can
&lt;br/&gt;&amp;gt; see the definitions for the functionDef and functionDeclSpecifiers grammar
&lt;br/&gt;&amp;gt; rules don't include any mention of __stdcall (since this is a
&lt;br/&gt;&amp;gt; Microsoft-specific extension).
&lt;br/&gt;&amp;gt; 
&lt;/div&gt;&lt;br/&gt;well, actually we .. and khronos headers, and usually all others,
&lt;br/&gt;use macro definitions to get around this non std qualifier.
&lt;br/&gt;&lt;br/&gt;However .. sure, you may patch gluegen as Wade suggest as well.
&lt;br/&gt;If so, pls offer me a git pull .. w/ unit tests, thx.
&lt;br/&gt;&lt;br/&gt;~Sven
&lt;br/&gt;&lt;div class='shrinkable-quote'&gt;&lt;br/&gt;&amp;gt; To fix it quick and dirty, you should be able to simply add __stdcall
&lt;br/&gt;&amp;gt; something like this:
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; functionDef {
&lt;br/&gt;&amp;gt; &amp;nbsp; &amp;nbsp; TypeBox tb = null;
&lt;br/&gt;&amp;gt; }
&lt;br/&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; : &amp;nbsp; #( NFunctionDef
&lt;br/&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; ( functionDeclSpecifiers)? 
&lt;br/&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; declarator[tb]
&lt;br/&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; (&amp;quot;__stdcall&amp;quot;)?
&lt;br/&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; (declaration | VARARGS)*
&lt;br/&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; compoundStatement
&lt;br/&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; )
&lt;br/&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; ;
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; I'm not quite sure where it goes in the grammar rule -- you might have to
&lt;br/&gt;&amp;gt; poke around a bit and make sure. And it may also need to go in other
&lt;br/&gt;&amp;gt; occurrences of functionDef in other *.g files.
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; Once you've fixed the grammar, recompile gluegen (making sure the ANTLR
&lt;br/&gt;&amp;gt; parser generation step doesn't throw any errors) and test it out on your
&lt;br/&gt;&amp;gt; input file.
&lt;br/&gt;&amp;gt; 
&lt;br/&gt;&amp;gt; To fix this &amp;quot;for real&amp;quot;, you'd probably need to do what they've done for GNU
&lt;br/&gt;&amp;gt; C -- create a new .g file for MS C and just override the parts of the
&lt;br/&gt;&amp;gt; grammar that are different. See the GnuC*.g files for an example.
&lt;br/&gt;&lt;/div&gt;
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/stdcall-not-recognized-tp3079928p3082244.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-3080779"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3080779</id>
		<title>Re: __stdcall not recognized</title>
		<published>2011-06-18T14:04:22Z</published>
		<updated>2011-06-18T14:04:22Z</updated>
		<author>
			<name>Wade Walker</name>
		</author>
		<content type="html">
			Hi Dino,
&lt;br/&gt;&lt;br/&gt;It looks like you might have to modify gluegen's C grammar slightly to make this work. If you check out the source and look in gluegen/src/java/com/jogamp/gluegen/cgram, you can see the ANTLR grammar files there (the *.g files). Inside HeaderParser.g and StdCParser.g, you can see the definitions for the functionDef and functionDeclSpecifiers grammar rules don't include any mention of __stdcall (since this is a Microsoft-specific extension).
&lt;br/&gt;&lt;br/&gt;To fix it quick and dirty, you should be able to simply add __stdcall something like this:
&lt;br/&gt;&lt;br/&gt;&lt;pre&gt;
functionDef {
    TypeBox tb = null;
}
        :   #( NFunctionDef
                ( functionDeclSpecifiers)? 
                declarator[tb]
                (&amp;quot;__stdcall&amp;quot;)?
                (declaration | VARARGS)*
                compoundStatement
            )
        ;
&lt;/pre&gt;&lt;br/&gt;I'm not quite sure where it goes in the grammar rule -- you might have to poke around a bit and make sure. And it may also need to go in other occurrences of functionDef in other *.g files.
&lt;br/&gt;&lt;br/&gt;Once you've fixed the grammar, recompile gluegen (making sure the ANTLR parser generation step doesn't throw any errors) and test it out on your input file.
&lt;br/&gt;&lt;br/&gt;To fix this &amp;quot;for real&amp;quot;, you'd probably need to do what they've done for GNU C -- create a new .g file for MS C and just override the parts of the grammar that are different. See the GnuC*.g files for an example.
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/stdcall-not-recognized-tp3079928p3080779.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-3079928"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-3079928</id>
		<title>__stdcall not recognized</title>
		<published>2011-06-18T08:07:06Z</published>
		<updated>2011-06-18T08:07:06Z</updated>
		<author>
			<name>Dino Puller</name>
		</author>
		<content type="html">
			Hi there,
&lt;br/&gt;&amp;nbsp; i'm playing with gluegen to see if it fits my needs. Actually it can't finish to parse my header because of __stdcall (callbacks routines). Any ideas? 
&lt;br/&gt;&lt;br/&gt;tnx,
&lt;br/&gt;&amp;nbsp; &amp;nbsp;Dino Puller
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/stdcall-not-recognized-tp3079928.html" />
		
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-2991281</id>
		<title>Re: Fail to compile gluegen-v2.0-rc2 ...</title>
		<published>2011-05-26T18:23:28Z</published>
		<updated>2011-05-26T18:23:28Z</updated>
		<author>
			<name>jiapei100</name>
		</author>
		<content type="html">
			&lt;br/&gt;Thanks Michael, but I guess it's because of this:
&lt;br/&gt;&lt;a href=&quot;http://forum.visionopen.com/viewtopic.php?f=27&amp;t=5826&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://forum.visionopen.com/viewtopic.php?f=27&amp;t=5826&lt;/a&gt;&lt;br/&gt;&lt;br/&gt;Cygwin's symbolic link, instead of the .exe file .
&lt;br/&gt;&lt;br/&gt;Is it possible that I don't use gcc to compile the native and specify my own C compiler?
&lt;br/&gt;&lt;br/&gt;Best Regards
&lt;br/&gt;Pei
&lt;br/&gt;&lt;br/&gt;
	&lt;div class=&quot;signature weak-color&quot;&gt;Welcome to Vision Open
&lt;a href=&quot;http://www.visionopen.com/&quot; title=&quot;Vision Open&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://www.visionopen.com&lt;/a&gt; 
&lt;/div&gt;
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/Fail-to-compile-gluegen-v2-0-rc2-tp2910008p2991281.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-2990110"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-2990110</id>
		<title>Re: Fail to compile gluegen-v2.0-rc2 ...</title>
		<published>2011-05-26T12:24:10Z</published>
		<updated>2011-05-26T12:24:10Z</updated>
		<author>
			<name>Michael Bien</name>
		</author>
		<content type="html">
			&amp;nbsp; On 05/26/2011 09:14 PM, jiapei100 [via jogamp] wrote:
&lt;br/&gt;&amp;gt;
&lt;br/&gt;&amp;gt;&amp;gt; ...\Java\Eclipse\gluegen\make\build.xml:404: Could not laun
&lt;br/&gt;&amp;gt;&amp;gt; ch gcc: java.io.IOException: Cannot run program &amp;quot;gcc&amp;quot; (in directory &amp;quot;
&lt;br/&gt;&amp;gt;&amp;gt; ...\Java\Eclipse\gluegen\build\obj&amp;quot;): CreateProcess error=5, Access is
&lt;br/&gt;&amp;gt;&amp;gt; &amp;nbsp; denied
&lt;br/&gt;looks like a user/access rights issue to me.
&lt;br/&gt;&lt;br/&gt;-michael
&lt;br/&gt;&lt;br/&gt;-- 
&lt;br/&gt;&lt;a href=&quot;http://michael-bien.com/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://michael-bien.com/&lt;/a&gt;&lt;br/&gt;&lt;br/&gt;
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/Fail-to-compile-gluegen-v2-0-rc2-tp2910008p2990110.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-2990046"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-2990046</id>
		<title>Re: Fail to compile gluegen-v2.0-rc2 ...</title>
		<published>2011-05-26T12:14:32Z</published>
		<updated>2011-05-26T12:14:32Z</updated>
		<author>
			<name>jiapei100</name>
		</author>
		<content type="html">
			&lt;br/&gt;Problem again....
&lt;br/&gt;I'm using today's git clone, say, git clone of May 26, 2011.
&lt;br/&gt;I successfully built gluegen and jogl under Ubuntu 11.04 . But now I'm using Windows7. Things might be a little bit different.
&lt;br/&gt;&lt;br/&gt;1)
&lt;br/&gt;If using DOS Prompt, I got the following errors:
&lt;br/&gt;&lt;blockquote class=&quot;quote dark-border-color&quot;&gt;&lt;div class=&quot;quote light-border-color&quot;&gt;
&lt;div class=&quot;quote-message&quot;&gt;BUILD FAILED
&lt;br/&gt;...\Java\Eclipse\gluegen\make\build.xml:623: The following
&lt;br/&gt;error occurred while executing this line:
&lt;br/&gt;...\Java\Eclipse\gluegen\make\build.xml:404: Could not laun
&lt;br/&gt;ch gcc: java.io.IOException: Cannot run program &amp;quot;gcc&amp;quot; (in directory &amp;quot;
&lt;br/&gt;...\Java\Eclipse\gluegen\build\obj&amp;quot;): CreateProcess error=5, Access is
&lt;br/&gt;&amp;nbsp;denied
&lt;/div&gt;
&lt;/div&gt;&lt;/blockquote&gt;
2) If build from within Cygwin, in order to use &amp;quot;gcc&amp;quot;, I got errors like:
&lt;br/&gt;&lt;blockquote class=&quot;quote dark-border-color&quot;&gt;&lt;div class=&quot;quote light-border-color&quot;&gt;
&lt;div class=&quot;quote-message shrinkable-quote&quot;&gt;BUILD FAILED
&lt;br/&gt;...\Java\Eclipse\gluegen\make\build.xml:679: The following
&lt;br/&gt;error occurred while executing this line:
&lt;br/&gt;...\Java\Eclipse\gluegen\make\build-test.xml:203: The follo
&lt;br/&gt;wing error occurred while executing this line:
&lt;br/&gt;...\Java\Eclipse\gluegen\make\build-test.xml:323: The follo
&lt;br/&gt;wing error occurred while executing this line:
&lt;br/&gt;...\Java\Eclipse\gluegen\make\build-test.xml:164: Could not
&lt;br/&gt;&amp;nbsp;launch gcc: java.io.IOException: Cannot run program &amp;quot;gcc&amp;quot; (in directory
&lt;br/&gt;&amp;quot;...\Java\Eclipse\gluegen\build\test\build\obj&amp;quot;): CreateProcess er
&lt;br/&gt;ror=5, Access is denied
&lt;/div&gt;
&lt;/div&gt;&lt;/blockquote&gt;
I'm pretty sure that I put gluegen and jogl under the same folder. What should I do to successfully build jogl and gluegen under Windows7?
&lt;br/&gt;&lt;br/&gt;Rgds
&lt;br/&gt;Pei
	&lt;div class=&quot;signature weak-color&quot;&gt;Welcome to Vision Open
&lt;a href=&quot;http://www.visionopen.com/&quot; title=&quot;Vision Open&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://www.visionopen.com&lt;/a&gt; 
&lt;/div&gt;
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/Fail-to-compile-gluegen-v2-0-rc2-tp2910008p2990046.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-2982504"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-2984812</id>
		<title>Re: Compilation failure on FreeBSD amd64 (eclipse swt packages not installed?)</title>
		<published>2011-05-25T08:54:55Z</published>
		<updated>2011-05-25T08:54:55Z</updated>
		<author>
			<name>jerron</name>
		</author>
		<content type="html">
			This tiny patch allows the source from sgothel's repos to build:
&lt;br/&gt;&lt;br/&gt;index aac3849..5e514bf 100644
&lt;br/&gt;--- a/make/build-common.xml
&lt;br/&gt;+++ b/make/build-common.xml
&lt;br/&gt;@@ -120,6 +120,9 @@
&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;lt;istrue value=&amp;quot;${isWindowsX86}&amp;quot; /&amp;gt;&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;lt;/condition&amp;gt;&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;lt;condition property=&amp;quot;swt.jar&amp;quot; value=&amp;quot;${project.root}/make/lib/swt/gtk-linux-x86_64/swt-debug.jar&amp;quot;&amp;gt;&lt;br/&gt;+ &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;lt;istrue value=&amp;quot;${isFreeBSDAMD64}&amp;quot; /&amp;gt;&lt;br/&gt;+ &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;lt;/condition&amp;gt;&lt;br/&gt;+ &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;lt;condition property=&amp;quot;swt.jar&amp;quot; value=&amp;quot;${project.root}/make/lib/swt/gtk-linux-x86_64/swt-debug.jar&amp;quot;&amp;gt;&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;lt;istrue value=&amp;quot;${isLinuxAMD64}&amp;quot; /&amp;gt;&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;lt;/condition&amp;gt;&lt;br/&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;lt;condition property=&amp;quot;swt.jar&amp;quot; value=&amp;quot;${project.root}/make/lib/swt/gtk-linux-x86/swt-debug.jar&amp;quot;&amp;gt;&lt;br/&gt;&lt;br/&gt;Of course, I've not tried running the unit tests yet.
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/Compilation-failure-on-FreeBSD-amd64-eclipse-swt-packages-not-installed-tp2981841p2984812.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-2984522"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-2984808</id>
		<title>Re: Compilation failure on FreeBSD amd64 (eclipse swt packages not installed?)</title>
		<published>2011-05-25T08:54:23Z</published>
		<updated>2011-05-25T08:54:23Z</updated>
		<author>
			<name>Wade Walker</name>
		</author>
		<content type="html">
			Whichever version of Eclipse you installed, that's the version of the SWT libraries you need. So if you installed Eclipse from &lt;a href=&quot;http://www.eclipse.org/downloads/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://www.eclipse.org/downloads/&lt;/a&gt;, then there should be a version of SWT at &lt;a href=&quot;http://www.eclipse.org/swt/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://www.eclipse.org/swt/&lt;/a&gt;&amp;nbsp;that matches it.
&lt;br/&gt;&lt;br/&gt;If it's an SWT version that we don't already have in jogl/make/lib/swt, just download it from &lt;a href=&quot;http://www.eclipse.org/swt/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://www.eclipse.org/swt/&lt;/a&gt;&amp;nbsp;and put it in there. If we already have the version, you just need to change jogl/make/build-common.xml as I mentioned before.
&lt;br/&gt;&lt;br/&gt;It's slightly more difficult to try to take the SWT from inside an Eclipse installation, because an installation will only contain the SWT libraries for that specific platform. For example, my Windows installation contains:
&lt;br/&gt;&lt;br/&gt;org.eclipse.swt_3.6.1.v3655c.jar
&lt;br/&gt;org.eclipse.swt.win32.win32.x86_64_3.6.1.v3655c.jar
&lt;br/&gt;&lt;br/&gt;You could copy these into jogl/make/lib/swt, but then you'd still be missing 32-bit Windows. But you can do this if there's no other option (like if your version of Eclipse is some sort of custom build for FreeBSD).
&lt;br/&gt;
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/Compilation-failure-on-FreeBSD-amd64-eclipse-swt-packages-not-installed-tp2981841p2984808.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-2984522"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-2984522</id>
		<title>Re: Compilation failure on FreeBSD amd64 (eclipse swt packages not installed?)</title>
		<published>2011-05-25T07:27:22Z</published>
		<updated>2011-05-25T07:27:22Z</updated>
		<author>
			<name>jerron</name>
		</author>
		<content type="html">
			I should actually mention that anything in the build system that mentions FreeBSD amd64 was actually put there by me. I did some work porting the library to that platform last year but then almost immediately had to stop Java OpenGL work. Now that I'm able to continue again, I'd like to get things back working again. I'm currently looking at getting hold of the necessary swt-debug jar files (suspect I'll be building them myself).
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/Compilation-failure-on-FreeBSD-amd64-eclipse-swt-packages-not-installed-tp2981841p2984522.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-2982481"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-2983815</id>
		<title>Re: Compilation failure on FreeBSD amd64 (eclipse swt packages not installed?)</title>
		<published>2011-05-25T03:25:43Z</published>
		<updated>2011-05-25T03:25:43Z</updated>
		<author>
			<name>jerron</name>
		</author>
		<content type="html">
			Er, by that I mean I have a native copy of eclipse installed without any Linux compatibility libraries.
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/Compilation-failure-on-FreeBSD-amd64-eclipse-swt-packages-not-installed-tp2981841p2983815.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-2983813"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-2983813</id>
		<title>Re: Compilation failure on FreeBSD amd64 (eclipse swt packages not installed?)</title>
		<published>2011-05-25T03:24:47Z</published>
		<updated>2011-05-25T03:24:47Z</updated>
		<author>
			<name>jerron</name>
		</author>
		<content type="html">
			Lo.
&lt;br/&gt;&lt;br/&gt;Is SWT installed as part of eclipse? If so, I do have eclipse installed so presumably it does work even if they don't actually distribute jar files.
&lt;br/&gt;&lt;br/&gt;
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/Compilation-failure-on-FreeBSD-amd64-eclipse-swt-packages-not-installed-tp2981841p2983813.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-2982481"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-2982504</id>
		<title>Re: Fail to compile gluegen-v2.0-rc2 ...</title>
		<published>2011-05-24T18:02:16Z</published>
		<updated>2011-05-24T18:02:16Z</updated>
		<author>
			<name>Wade Walker</name>
		</author>
		<content type="html">
			Hi Pei,
&lt;br/&gt;&lt;br/&gt;I'm glad to hear that gluegen and jogl are building for you now &lt;img class='smiley' src='http://n3.nabble.com/images/smiley/smiley_grin.gif' /&gt;&lt;br/&gt;&lt;br/&gt;&lt;blockquote class=&quot;quote dark-border-color&quot;&gt;&lt;div class=&quot;quote light-border-color&quot;&gt;
&lt;div class=&quot;quote-author&quot; style=&quot;font-weight: bold;&quot;&gt;jiapei100 wrote&lt;/div&gt;
&lt;div class=&quot;quote-message&quot;&gt;However, there are always two red-crosses on the project gluegen, within Eclipse 3.6.2 IDE.
&lt;br/&gt;The two red-crosses seem to point to gluegen-cpptasks-base.xml and gluegen-cpptasks-custom.xml . Why is it so? How can I correctly specify cpptasks directories?
&lt;/div&gt;
&lt;/div&gt;&lt;/blockquote&gt;
I think these are due to the fact that Eclipse assumes that build XML files are in the project root, so it doesn't know how to find JOGL's XML files, which are all down in the make directory. There may be some way to fix this, but I haven't looked for one yet.
&lt;br/&gt;&lt;br/&gt;Right now, I just close the XML build files in Eclipse, then delete those errors from the Problems view. As long as you don't open the XML build files in an Eclipse editor, the errors won't reappear.
&lt;br/&gt;&lt;br/&gt;&lt;blockquote class=&quot;quote dark-border-color&quot;&gt;&lt;div class=&quot;quote light-border-color&quot;&gt;
&lt;div class=&quot;quote-author&quot; style=&quot;font-weight: bold;&quot;&gt;jiapei100 wrote&lt;/div&gt;
&lt;div class=&quot;quote-message&quot;&gt;By the way, there seems to be some simple errors for jogl-demos, such as 
&lt;br/&gt;...
&lt;br/&gt;But, I still have a lot of error messages in 
&lt;br/&gt;jogl-demos/javabullet.demos.opengl ...
&lt;br/&gt;None of the four files under jogl-demos/javabullet.demos.opengl can be compiled till now. 
&lt;br/&gt;&lt;br/&gt;Can you please help to update jogl-demos at your convenience?
&lt;/div&gt;
&lt;/div&gt;&lt;/blockquote&gt;
Those, I'm not sure about. I haven't tried building the JOGL demos yet.
&lt;br/&gt;
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/Fail-to-compile-gluegen-v2-0-rc2-tp2910008p2982504.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-2982001"/>
	</entry>
	<entry>
		<id>tag:jogamp.762907.n3.nabble.com,2006:post-2982481</id>
		<title>Re: Compilation failure on FreeBSD amd64 (eclipse swt packages not installed?)</title>
		<published>2011-05-24T17:53:03Z</published>
		<updated>2011-05-24T17:53:03Z</updated>
		<author>
			<name>Wade Walker</name>
		</author>
		<content type="html">
			Hi Jerron,
&lt;br/&gt;&lt;br/&gt;The SWT library is required only for some of the unit tests. Since JOGL can be displayed in an SWT app, we have unit tests for those cases. The SWT libraries are in jogl/make/lib/swt. SWT doesn't appear to support FreeBSD directly, but the Linux/GTK version should work on FreeBSD if you have the Linux GTK port installed (see &lt;a href=&quot;http://forums.freebsd.org/archive/index.php/t-7279.html&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot; link=&quot;external&quot;&gt;http://forums.freebsd.org/archive/index.php/t-7279.html&lt;/a&gt;&amp;nbsp;for info).
&lt;br/&gt;&lt;br/&gt;But if you just want to compile JOGL and you don't care if the SWT unit test runs, all you need to do is modify the jogl/make/build-common.xml to select the Linux version of SWT if it detects a FreeBSD build. Search for &amp;quot;isFreeBSD&amp;quot; in the XML files and you'll see how other parts of the build sense FreeBSD.
&lt;br/&gt;
	
			
		</content>
		<link rel="alternate" type="text/html" href="http://forum.jogamp.org/Compilation-failure-on-FreeBSD-amd64-eclipse-swt-packages-not-installed-tp2981841p2982481.html" />
		<thr:in-reply-to ref="tag:jogamp.762907.n3.nabble.com,2006:post-2981841"/>
	</entry>
</feed>
