- include SDK in gradle build

- add option to build natives / SDK to gradle properties
- update SDK properties file with jme version
experimental
Normen Hansen 11 years ago
parent 9877c83f92
commit d4546223fc
  1. 2
      common.gradle
  2. 4
      gradle.properties
  3. 2
      jme3-examples/build.gradle
  4. 4
      sdk/build.gradle
  5. 35
      settings.gradle

@ -15,7 +15,7 @@ sourceCompatibility = '1.5'
[compileJava, compileTestJava]*.options*.encoding = 'UTF-8' [compileJava, compileTestJava]*.options*.encoding = 'UTF-8'
repositories { repositories {
mavenCentral(); mavenCentral()
maven{ maven{
url "http://nifty-gui.sourceforge.net/nifty-maven-repo" url "http://nifty-gui.sourceforge.net/nifty-maven-repo"
} }

@ -5,6 +5,10 @@ jmeMainVersion = 3.1
# Version addition -pre-alpha-svn, -Stable, -Beta # Version addition -pre-alpha-svn, -Stable, -Beta
jmeVersionSuffix = -pre-alpha-svn jmeVersionSuffix = -pre-alpha-svn
# specify if SDK and Native libraries get built
buildSdkProject = true
buildNativeProjects = true
# Path to android NDK for building native libraries # Path to android NDK for building native libraries
#ndkPath=/Users/normenhansen/Documents/Code-Import/android-ndk-r7 #ndkPath=/Users/normenhansen/Documents/Code-Import/android-ndk-r7
ndkPath = D:/android/android-ndk-r8e ndkPath = D:/android/android-ndk-r8e

@ -87,9 +87,11 @@ task dist (dependsOn: ['build', ':jme3-jogl:jar', ':jme3-bullet:jar']){
into '../dist/opt/native-bullet' into '../dist/opt/native-bullet'
rename {project(':jme3-bullet').name+".jar"} rename {project(':jme3-bullet').name+".jar"}
} }
if(buildNativeProjects){
copy { copy {
from project(':jme3-bullet-native').jar.archivePath from project(':jme3-bullet-native').jar.archivePath
into '../dist/opt/native-bullet' into '../dist/opt/native-bullet'
rename {"jme3-bullet-natives.jar"} rename {"jme3-bullet-natives.jar"}
} }
}
} }

@ -333,6 +333,10 @@ ant.properties['plugins.version'] = jmeVersion
ant.properties['app.version']= jmeMainVersion + jmeVersionSuffix ant.properties['app.version']= jmeMainVersion + jmeVersionSuffix
task buildSdk(dependsOn: [copyBaseLibs, copyProjectLibs, createProjectXml, createBaseXml]) <<{ task buildSdk(dependsOn: [copyBaseLibs, copyProjectLibs, createProjectXml, createBaseXml]) <<{
ant.propertyfile(file: "nbproject/project.properties") {
entry( key: "plugins.version", value: "${jmeVersion}")
entry( key: "app.version", value: "${jmeMainVersion + jmeVersionSuffix}")
}
ant.ant(dir: ".", antfile: "build.xml", target: "build") ant.ant(dir: ".", antfile: "build.xml", target: "build")
} }

@ -3,13 +3,6 @@
**/ **/
rootProject.name = 'jmonkeyengine' rootProject.name = 'jmonkeyengine'
/**
* You can enable or disable different subprojects of the build here.
*
* The SDK will only be built if the appropriate library folders exist,
* call the "prepareSdk" target to prepare building the SDK.
**/
// Core classes, should work on all java platforms // Core classes, should work on all java platforms
include 'jme3-core' include 'jme3-core'
include 'jme3-effects' include 'jme3-effects'
@ -31,30 +24,16 @@ include 'jme3-android'
//native builds //native builds
include 'jme3-bullet' //java include 'jme3-bullet' //java
include 'jme3-bullet-native' //cpp if(buildNativeProjects){
include 'jme3-android-native' //cpp include 'jme3-bullet-native' //cpp
include 'jme3-android-native' //cpp
}
// Test Data project // Test Data project
include 'jme3-testdata' include 'jme3-testdata'
// Example projects // Example projects
include 'jme3-examples' include 'jme3-examples'
//include 'sdk' if(buildSdkProject){
include 'sdk'
// Find the directories containing a 'build.gradle' file in the root directory }
// of the project. That is, every directory containing a 'build.gradle' will
// be automatically the subproject of this project.
/*def subDirs = rootDir.listFiles(new FileFilter() {
public boolean accept(File file) {
if (!file.isDirectory()) {
return false
}
return new File(file, 'build.gradle').isFile()
}
});
subDirs.each { File dir ->
include dir.name
}*/
Loading…
Cancel
Save