Trying to test distribution of an app in SDK 3.2 with Minie Bullet Physics

Hi,

so I just wanted to build a distribution version of an application made with JME 3.2.4-stable-sdk1 for others to execute on their machines.

I’m using Minie for physics simulation so I added the Minie and Heart jars (*for32) under Project Properties / Libraries and removed all other bullet jars.

Then I checked “Create Windows 64bit Application” under Properties / Application / Desktop.

Then I clicked “Clean & Build” and a bunch of files show up under my projects “dist” folder. If I understand it correctly I should distribute the compiled “Windows-x64.zip” file.

Now if I extract that onto my own desktop and try to run it using the generated launcher exe it crashes, telling me something about a missing JRE. But I didn’t bundle any JRE (unchecked in the properties) so I guess that is to be expected.

But when I enter the contained app folder and try to run the apps jar file (next to the dlls and lib folder) directly using java -jar App.jar it gives me the following exception:

...
Juli 22, 2020 4:15:32 PM com.jme3.app.LegacyApplication handleError
SEVERE: Uncaught exception thrown in Thread[jME3 Main,5,main]
java.lang.NoClassDefFoundError: com/jme3/bullet/objects/PhysicsRigidBody
        at screens.Game.init(Game.java:136)
...

It points to the first line where I create a rigid body using new PhysicsRigidBody( ... ).

I can see a “bulletjme.dll” and the appropriate Minie / Heart jars included with the distribution build.

Am I missing something? Is this even Minie related or some issue with the SDK?

1 Like

The issues sounds familiar:

The bottom line: The “desktop distribution” scripts in the SDK make assumptions that Minie violates. In Maud I worked around the issue by adding the Minie JARs to the ANT project twice, under different names.

1 Like

There are two problems:
The SDKs way of downloading the jre doenst work anymore now that oracle downloads require a sign in.

The other thing is a regular java thing i suppose?
When launching the App.jar you need to specify all the libs via classpath (-cp) or create a fatJar, but that is a different topic.

1 Like

Thanks for the info!
I will take a closer look at that other thread.