Building jME-SDK issues

Thanks @grizeldi! Found it here. The SDK release date seems to be in line with the v3.1.0-beta1 tag of the engine so it’s good enough for me. I guess anyone hoping to build the SDK from source will be disappointed.

OK. In case someone will be looking for a solution here. I found if you download jmonkeyengine from https://github.com/jMonkeyEngine/jmonkeyengine. Then run gradlew.bat locally. Then run it again with the parameter install:
gradlew.bat install
That is going to create your local repositories.That’s is what you actually need to solve the trouble with building the SDK.
Next thing is to check the version of the newly installed JMonkeyEngine. Go to (Windows) %USER_HOM%/.m2/repository/org/jmonkeyengine/jme3-jbullet folder and check the name of the subfolder which is the version you are looking for.
Then open build.gradle in the SDK folder, find ext.jmeEngineVersion = “3.1.0-master-SNAPSHOT” (in a particular case it could be different) and replace it with ext.jmeEngineVersion = “3.2.0-SNAPSHOT” (whuch also was my specific case).
The rest is easy. run gradlew.bat in SDK folder and Voila! You got your JME3 SDK built!
( I hope )

I completely forgot to update this thread :confused:
Take a look at build_engine.sh, it does what you explained but on Linux only.

However you should be able to Transfer :stuck_out_tongue:

Btw: the sdk is made for 3.1 only so use at your own risk

Thanks, Darkchaos.
I’ll figure this out.

Hi,

I’m getting BUILD FAILED after cloning from https://github.com/jMonkeyEngine/sdk.git. See errors details:

$ gradlew buildSdk
Full Version: 3.1-beta1-ios-SNAPSHOT
POM Version: 3.1.0-beta1-ios-SNAPSHOT
NBM Revision: 1655
NBM UC Suffix: stable/3.1/plugins

FAILURE: Build failed with an exception.

* Where:
Build file 'D:\java\git\repos\sdk\build.gradle' line: 138

* What went wrong:
A problem occurred evaluating root project 'sdk'.
> Could not resolve all dependencies for configuration ':corelibs'.
   > Could not resolve org.jmonkeyengine:jme3-jbullet:3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT.
     Required by:
         :sdk:unspecified
      > Could not resolve org.jmonkeyengine:jme3-jbullet:3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT.
         > Could not get resource 'http://nifty-gui.sourceforge.net/nifty-maven-repo/org/jmonkeyengine/jme3-jbullet/3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT/jme3-jbullet-3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT.jar'.
            > Could not HEAD 'http://nifty-gui.sourceforge.net/nifty-maven-repo/org/jmonkeyengine/jme3-jbullet/3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT/jme3-jbullet-3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT.jar'.
               > Connection reset
   > Could not resolve org.jmonkeyengine:jme3-jogg:3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT.
     Required by:
         :sdk:unspecified
      > Could not resolve org.jmonkeyengine:jme3-jogg:3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT.
         > Could not get resource 'http://nifty-gui.sourceforge.net/nifty-maven-repo/org/jmonkeyengine/jme3-jogg/3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT/jme3-jogg-3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT.jar'.
            > Could not HEAD 'http://nifty-gui.sourceforge.net/nifty-maven-repo/org/jmonkeyengine/jme3-jogg/3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT/jme3-jogg-3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT.jar'.
               > Connection reset
   > Could not resolve org.jmonkeyengine:jme3-networking:3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT.
     Required by:
         :sdk:unspecified
      > Could not resolve org.jmonkeyengine:jme3-networking:3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT.
         > Could not get resource 'http://nifty-gui.sourceforge.net/nifty-maven-repo/org/jmonkeyengine/jme3-networking/3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT/jme3-networking-3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT.jar'.
            > Could not HEAD 'http://nifty-gui.sourceforge.net/nifty-maven-repo/org/jmonkeyengine/jme3-networking/3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT/jme3-networking-3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT.jar'.
               > Connection reset
   > Could not resolve org.jmonkeyengine:jme3-niftygui:3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT.
     Required by:
         :sdk:unspecified
      > Could not resolve org.jmonkeyengine:jme3-niftygui:3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT.
         > Could not get resource 'http://nifty-gui.sourceforge.net/nifty-maven-repo/org/jmonkeyengine/jme3-niftygui/3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT/jme3-niftygui-3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT.jar'.
            > Could not HEAD 'http://nifty-gui.sourceforge.net/nifty-maven-repo/org/jmonkeyengine/jme3-niftygui/3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT/jme3-niftygui-3.1.0-3.1-beta1-ios-SNAPSHOT-SNAPSHOT.jar'.
               > Connection reset

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug
option to get more log output.

BUILD FAILED

Total time: 1 mins 3.081 secs

This looks like gradle can’t find the required libraries. Have you built engine from source?

I pushed some changes now, in general you have to execute build_engine.sh and then it should find those engine libraries.

Let me know if it works now.

Both build_endine.sh and “gradlew buildSdk” working fine after git pull.
Thanks

Got the same error on Windows using gradlew.bat:

E:\Projetos\JME3\SDK\sdk>gradlew.bat
Full Version: 3.1-1665
POM Version: 3.1.0-SNAPSHOT
NBM Revision: 1665
NBM UC Suffix: nightly/3.1/plugins

FAILURE: Build failed with an exception.

* Where:
Build file 'E:\Projetos\JME3\SDK\sdk\build.gradle' line: 142

* What went wrong:
A problem occurred evaluating root project 'sdk'.
> Could not resolve all dependencies for configuration ':corelibs'.
   > Could not find org.jmonkeyengine:jme3-jogg:3.1.0-SNAPSHOT.
     Searched in the following locations:

I was able to build after editing the build.gradle, as follows:

1 - Setting engine version to beta1:

ext.jmeEngineVersion = "3.1.0-beta1"

2 - Removing the dependency of non-core libs by commenting the line:

    //optlibs dep("org.jmonkeyengine:jme3-jbullet:$jmeEngineVersion", true, true)
    //optlibs dep("org.jmonkeyengine:jme3-jogl:$jmeEngineVersion", true, true)
    //optlibs dep("org.jmonkeyengine:jme3-android:$jmeEngineVersion", true, true)
    //optlibs dep("org.jmonkeyengine:jme3-ios:$jmeEngineVersion", true, true)
    //optlibs dep("org.jmonkeyengine:jme3-android-native:$jmeEngineVersion", true, true)
    //optlibs dep("org.jmonkeyengine:jme3-bullet-native-android:$jmeEngineVersion", true, true)
    //testdatalibs dep("org.jmonkeyengine:jme3-testdata:$jmeEngineVersion", false, false)

    //examplelibs dep("org.jmonkeyengine:jme3-examples:$jmeEngineVersion", false, true)

Hope it helps someone else.

Sounds like you didn’t build the engine first using the build engine script mentioned a few posts up.

This one?

gradlew.bat buildSdk

I’m on windows, so I can’t use build_endine.sh.

Well, one of those builds the SDK and the other builds the engine. Note: engine != SDK SDK != engine.

So… if you don’t manage to build the engine jars then you won’t find the engine jars when you try to build the SDK.

What you are doing is hacking your SDK build to use the jars from jcenter instead of the ones that match the code you have checked out. But then you might as well just download the 3.1 beta SDK, I guess.

This is the main problem here.
There are some libraries which the engine doesn’t distribute but the sdk needs (or rather which is provided for user projects).

Those libraries were present on the server we lost and that means I had to hack something around for travis to work. I didn’t have Windows in mind and it’s not that easy since not everybody has installed a git environment but rather only downloads the zip of the repo.

What you currently did is removed bullet, android, ios, ogl and jogg libraries from your sdk. If you don’t need them, you can stick with that solution.

If not you could open up the build_engine and see what it does. It’s really simple code.
Essentially something like downloading the engine repo to engine folder and then gradlew.bat assemble install.
I also did it on my windows machine but I don’t remember if manually or just using Source Tree’s Git Shell (which every git installation should provide).

I built sdk on windows.

Try next steps. It worked for me:

  1. Download engine sources.
  2. In cmd make gradlew.bat build
  3. After engine builded, gradlew.bat install .
  4. Download sdk.
  5. gradlew.bat buildSdk.
  6. It downloads netbeans. Open it. It has opened project. Right click on it and find something like “make installers” or “make zip” (I can’t tell you correctly, because by default netbeans get language of my system and it is not English :frowning: )
  7. It makes installers. You install it.
  8. I don’t know how it happened( oh, I know, it’s my hands from an ass), but it made sdk with 3.1.0-beta1 and 3.2.0 versions. 3.1.0-beta1 by default (but I just replaced it by 3.2.0 libraries and it worked well).
  9. ???
  10. Profit. I got sdk with both native bullet working and it is not crashed when you switch material to PBR.

Note: gradlew install should also build first… so in theory step 2 is unnecessary.

…at least when I need to build against the latest engine jars, I just run gradlew install and it’s fine.

I’m trying to build the latest SDK/Engine from the Master Branch. I forked the SDK project on GitHub, and cloned it locally. Then I checked out the master branch (of the SDK). When I try to build with, “gradlew buildSDK” I receive the following:

gbutler@gbutler-Bonobo-Extreme:~/netbeans/Git/sdk$ ./gradlew buildSdk
Full Version: 3.1-1665
POM Version: 3.1.0-SNAPSHOT
NBM Revision: 1665
NBM UC Suffix: nightly/3.1/plugins

FAILURE: Build failed with an exception.

* Where:
Build file '/mnt/userspace/gbutler/netbeans/Git/sdk/build.gradle' line: 141

* What went wrong:
A problem occurred evaluating root project 'sdk'.
> Could not resolve all dependencies for configuration ':corelibs'.
   > Could not find org.jmonkeyengine:jme3-jogg:3.1.0-SNAPSHOT.
     Searched in the following locations:
         file:/home/gbutler/.m2/repository/org/jmonkeyengine/jme3-jogg/3.1.0-SNAPSHOT/maven-metadata.xml
         file:/home/gbutler/.m2/repository/org/jmonkeyengine/jme3-jogg/3.1.0-SNAPSHOT/jme3-jogg-3.1.0-SNAPSHOT.pom
         file:/home/gbutler/.m2/repository/org/jmonkeyengine/jme3-jogg/3.1.0-SNAPSHOT/jme3-jogg-3.1.0-SNAPSHOT.jar
         http://jcenter.bintray.com/org/jmonkeyengine/jme3-jogg/3.1.0-SNAPSHOT/maven-metadata.xml
         http://jcenter.bintray.com/org/jmonkeyengine/jme3-jogg/3.1.0-SNAPSHOT/jme3-jogg-3.1.0-SNAPSHOT.pom
         http://jcenter.bintray.com/org/jmonkeyengine/jme3-jogg/3.1.0-SNAPSHOT/jme3-jogg-3.1.0-SNAPSHOT.jar
         http://updates.jmonkeyengine.org/maven/org/jmonkeyengine/jme3-jogg/3.1.0-SNAPSHOT/maven-metadata.xml
         http://updates.jmonkeyengine.org/maven/org/jmonkeyengine/jme3-jogg/3.1.0-SNAPSHOT/jme3-jogg-3.1.0-SNAPSHOT.pom
         http://updates.jmonkeyengine.org/maven/org/jmonkeyengine/jme3-jogg/3.1.0-SNAPSHOT/jme3-jogg-3.1.0-SNAPSHOT.jar
         http://nifty-gui.sourceforge.net/nifty-maven-repo/org/jmonkeyengine/jme3-jogg/3.1.0-SNAPSHOT/maven-metadata.xml
         http://nifty-gui.sourceforge.net/nifty-maven-repo/org/jmonkeyengine/jme3-jogg/3.1.0-SNAPSHOT/jme3-jogg-3.1.0-SNAPSHOT.pom
         http://nifty-gui.sourceforge.net/nifty-maven-repo/org/jmonkeyengine/jme3-jogg/3.1.0-SNAPSHOT/jme3-jogg-3.1.0-SNAPSHOT.jar
         https://jitpack.io/org/jmonkeyengine/jme3-jogg/3.1.0-SNAPSHOT/maven-metadata.xml
         https://jitpack.io/org/jmonkeyengine/jme3-jogg/3.1.0-SNAPSHOT/jme3-jogg-3.1.0-SNAPSHOT.pom
         https://jitpack.io/org/jmonkeyengine/jme3-jogg/3.1.0-SNAPSHOT/jme3-jogg-3.1.0-SNAPSHOT.jar
     Required by:
         :sdk:unspecified
   > Could not find org.jmonkeyengine:jme3-networking:3.1.0-SNAPSHOT.
     Searched in the following locations:
         file:/home/gbutler/.m2/repository/org/jmonkeyengine/jme3-networking/3.1.0-SNAPSHOT/maven-metadata.xml
         file:/home/gbutler/.m2/repository/org/jmonkeyengine/jme3-networking/3.1.0-SNAPSHOT/jme3-networking-3.1.0-SNAPSHOT.pom
         file:/home/gbutler/.m2/repository/org/jmonkeyengine/jme3-networking/3.1.0-SNAPSHOT/jme3-networking-3.1.0-SNAPSHOT.jar
         http://jcenter.bintray.com/org/jmonkeyengine/jme3-networking/3.1.0-SNAPSHOT/maven-metadata.xml
         http://jcenter.bintray.com/org/jmonkeyengine/jme3-networking/3.1.0-SNAPSHOT/jme3-networking-3.1.0-SNAPSHOT.pom
         http://jcenter.bintray.com/org/jmonkeyengine/jme3-networking/3.1.0-SNAPSHOT/jme3-networking-3.1.0-SNAPSHOT.jar
         http://updates.jmonkeyengine.org/maven/org/jmonkeyengine/jme3-networking/3.1.0-SNAPSHOT/maven-metadata.xml
         http://updates.jmonkeyengine.org/maven/org/jmonkeyengine/jme3-networking/3.1.0-SNAPSHOT/jme3-networking-3.1.0-SNAPSHOT.pom
         http://updates.jmonkeyengine.org/maven/org/jmonkeyengine/jme3-networking/3.1.0-SNAPSHOT/jme3-networking-3.1.0-SNAPSHOT.jar
         http://nifty-gui.sourceforge.net/nifty-maven-repo/org/jmonkeyengine/jme3-networking/3.1.0-SNAPSHOT/maven-metadata.xml
         http://nifty-gui.sourceforge.net/nifty-maven-repo/org/jmonkeyengine/jme3-networking/3.1.0-SNAPSHOT/jme3-networking-3.1.0-SNAPSHOT.pom
         http://nifty-gui.sourceforge.net/nifty-maven-repo/org/jmonkeyengine/jme3-networking/3.1.0-SNAPSHOT/jme3-networking-3.1.0-SNAPSHOT.jar
         https://jitpack.io/org/jmonkeyengine/jme3-networking/3.1.0-SNAPSHOT/maven-metadata.xml
         https://jitpack.io/org/jmonkeyengine/jme3-networking/3.1.0-SNAPSHOT/jme3-networking-3.1.0-SNAPSHOT.pom
         https://jitpack.io/org/jmonkeyengine/jme3-networking/3.1.0-SNAPSHOT/jme3-networking-3.1.0-SNAPSHOT.jar
     Required by:
         :sdk:unspecified
   > Could not find org.jmonkeyengine:jme3-niftygui:3.1.0-SNAPSHOT.
     Searched in the following locations:
         file:/home/gbutler/.m2/repository/org/jmonkeyengine/jme3-niftygui/3.1.0-SNAPSHOT/maven-metadata.xml
         file:/home/gbutler/.m2/repository/org/jmonkeyengine/jme3-niftygui/3.1.0-SNAPSHOT/jme3-niftygui-3.1.0-SNAPSHOT.pom
         file:/home/gbutler/.m2/repository/org/jmonkeyengine/jme3-niftygui/3.1.0-SNAPSHOT/jme3-niftygui-3.1.0-SNAPSHOT.jar
         http://jcenter.bintray.com/org/jmonkeyengine/jme3-niftygui/3.1.0-SNAPSHOT/maven-metadata.xml
         http://jcenter.bintray.com/org/jmonkeyengine/jme3-niftygui/3.1.0-SNAPSHOT/jme3-niftygui-3.1.0-SNAPSHOT.pom
         http://jcenter.bintray.com/org/jmonkeyengine/jme3-niftygui/3.1.0-SNAPSHOT/jme3-niftygui-3.1.0-SNAPSHOT.jar
         http://updates.jmonkeyengine.org/maven/org/jmonkeyengine/jme3-niftygui/3.1.0-SNAPSHOT/maven-metadata.xml
         http://updates.jmonkeyengine.org/maven/org/jmonkeyengine/jme3-niftygui/3.1.0-SNAPSHOT/jme3-niftygui-3.1.0-SNAPSHOT.pom
         http://updates.jmonkeyengine.org/maven/org/jmonkeyengine/jme3-niftygui/3.1.0-SNAPSHOT/jme3-niftygui-3.1.0-SNAPSHOT.jar
         http://nifty-gui.sourceforge.net/nifty-maven-repo/org/jmonkeyengine/jme3-niftygui/3.1.0-SNAPSHOT/maven-metadata.xml
         http://nifty-gui.sourceforge.net/nifty-maven-repo/org/jmonkeyengine/jme3-niftygui/3.1.0-SNAPSHOT/jme3-niftygui-3.1.0-SNAPSHOT.pom
         http://nifty-gui.sourceforge.net/nifty-maven-repo/org/jmonkeyengine/jme3-niftygui/3.1.0-SNAPSHOT/jme3-niftygui-3.1.0-SNAPSHOT.jar
         https://jitpack.io/org/jmonkeyengine/jme3-niftygui/3.1.0-SNAPSHOT/maven-metadata.xml
         https://jitpack.io/org/jmonkeyengine/jme3-niftygui/3.1.0-SNAPSHOT/jme3-niftygui-3.1.0-SNAPSHOT.pom
         https://jitpack.io/org/jmonkeyengine/jme3-niftygui/3.1.0-SNAPSHOT/jme3-niftygui-3.1.0-SNAPSHOT.jar
     Required by:
         :sdk:unspecified

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

BUILD FAILED

Total time: 21.036 secs
gbutler@gbutler-Bonobo-Extreme:~/netbeans/Git/sdk$ 

Should I be trying to use a different value for this?

ext.jmeEngineVersion = "3.1.0-SNAPSHOT"

OK, I see I misunderstood some steps. I needed to build/install the engine first using:

gradlew build
gradlew install

from the downloaded engine source. Once I did that, and then retried building the SDK, I get the following error:

gbutler@gbutler-Bonobo-Extreme:~/netbeans/Git/sdk$ ./gradlew buildSdk
Full Version: 3.1-1665
POM Version: 3.1.0-SNAPSHOT
NBM Revision: 1665
NBM UC Suffix: nightly/3.1/plugins
:copyBaseLibs
:copyProjectLibs
:copyTestSources
:createBaseXml
:createProjectXml UP-TO-DATE
:downloadAvian
:checkPlatformConfig UP-TO-DATE
:overrideHarness FAILED

FAILURE: Build failed with an exception.

* Where:
Build file '/mnt/userspace/gbutler/netbeans/Git/sdk/build.gradle' line: 500

* What went wrong:
Execution failed for task ':overrideHarness'.
> Cannot find targetFile: /mnt/userspace/gbutler/netbeans/Git/sdk/netbeans/harness/launchers/app.exe

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

BUILD FAILED

Total time: 4.793 secs
gbutler@gbutler-Bonobo-Extreme:~/netbeans/Git/sdk$ 

Any thoughts? It doesn’t appear to have downloaded/created a netbeans sub-folder within the sdk project. Should I do that manually? Can I soft-link to an already downloaded Netbeans 8.1 or 8.2 instance? OK to use 8.2?

OK, so, I created a soft-link from …/sdk/netbeans -> …/netbeans-8.1 that I already had installed. When I did that, the build succeeded. I then did a “gradlew clean” and then changed the soft-link for Netbeans to …/sdk/netbeans -> …/netbeans-8.2 that I already had installed. Again, the build succeeded. Should the next step be to make an installer?

OK, so the next step appeared to be simply running it using:

gradlew run

Nice!