Merge pull request #624 from jMonkeyEngine/revert-573-cleanup_build_scripts

Revert "Cleanup build scripts (3.1)"
revert-671-backport_changes_from_3.2
empirephoenix 8 years ago committed by GitHub
commit 8214346e8b
  1. 1
      .gitignore
  2. 39
      .travis.yml
  3. 5
      build.gradle
  4. 19
      common.gradle
  5. 3
      gradle.properties
  6. 4
      jme3-bullet-native-android/build.gradle
  7. 2
      jme3-bullet-native/build.gradle
  8. 4
      jme3-examples/build.gradle
  9. BIN
      private/www-updater.key.enc
  10. 11
      version.gradle

1
.gitignore vendored

@ -14,7 +14,6 @@
*.jnilib
*.dylib
*.iml
.gradletasknamecache
.DS_Store
/jme3-core/src/main/resources/com/jme3/system/version.properties
/jme3-*/build/

@ -1,38 +1,17 @@
language: java
sudo: false
branches:
only:
- master
- v3.1
matrix:
include:
- jdk: oraclejdk8
os: linux
env: UPLOAD_ALL=true
- jdk: openjdk7
os: linux
- os: osx
before_install:
- git fetch --unshallow
addons:
ssh_known_hosts: updates.jmonkeyengine.org
before_cache:
- rm -f $HOME/.gradle/caches/modules-2/modules-2.lock
- rm -fr $HOME/.gradle/caches/*/plugin-resolution/
cache:
directories:
- $HOME/.gradle/caches/
- $HOME/.gradle/wrapper/
script:
- ./gradlew check
after_success:
- '[ -n "$TRAVIS_TAG" ] && [ "$TRAVIS_PULL_REQUEST" == "false" ] && [ -n "$UPLOAD_ALL" ] && ./gradlew bintrayUpload || :'
notifications:
slack:
on_success: change
@ -40,6 +19,12 @@ notifications:
rooms:
secure: "PWEk4+VL986c3gAjWp12nqyifvxCjBqKoESG9d7zWh1uiTLadTHhZJRMdsye36FCpz/c/Jt7zCRO/5y7FaubQptnRrkrRfjp5f99MJRzQVXnUAM+y385qVkXKRKd/PLpM7XPm4AvjvxHCyvzX2wamRvul/TekaXKB9Ti5FCN87s="
install:
- ./gradlew assemble
script:
- ./gradlew check
before_deploy:
- ./gradlew createZipDistribution
- export RELEASE_DIST=$(ls build/distributions/*.zip)
@ -55,6 +40,9 @@ deploy:
repo: jMonkeyEngine/jmonkeyengine
tags: true
before_install:
- git fetch --unshallow
- "[ $TRAVIS_PULL_REQUEST == 'false' ] && openssl aes-256-cbc -K $encrypted_a1949b55824a_key -iv $encrypted_a1949b55824a_iv -in private/www-updater.key.enc -out private/www-updater.key -d || :"
# before_install:
# required libs for android build tools
@ -66,4 +54,7 @@ deploy:
# 7z x ndk.bin -y > /dev/null
# export ANDROID_NDK=`pwd`/android-ndk-r10c
after_success:
- '[ -n "$TRAVIS_TAG" ] && [ "$TRAVIS_PULL_REQUEST" == "false" ] && ./gradlew bintrayUpload || :'
# - '[ "$TRAVIS_BRANCH" == "v3.1" ] && [ "$TRAVIS_PULL_REQUEST" == "false" ] && ./gradlew uploadArchives || :'
# - '[ -n "$TRAVIS_TAG" ] && [ "$TRAVIS_PULL_REQUEST" == "false" ] && ./gradlew uploadArchives bintrayUpload || :'

@ -29,8 +29,8 @@ task run(dependsOn: ':jme3-examples:run') {
defaultTasks 'run'
task libDist(dependsOn: subprojects.build, description: 'Builds and copies the engine binaries, sources and javadoc to build/libDist') {
doLast {
task libDist(dependsOn: subprojects.build) << {
// description 'Builds and copies the engine binaries, sources and javadoc to build/libDist'
File libFolder = mkdir("$buildDir/libDist/lib")
File sourceFolder = mkdir("$buildDir/libDist/sources")
File javadocFolder = mkdir("$buildDir/libDist/javadoc")
@ -60,7 +60,6 @@ task libDist(dependsOn: subprojects.build, description: 'Builds and copies the e
}
}
}
}
task createZipDistribution(type:Zip,dependsOn:["dist","libDist"], description:"Package the nightly zip distribution"){
archiveName "jME" + jmeFullVersion + ".zip"

@ -18,11 +18,16 @@ repositories {
}
}
configurations {
deployerJars
}
dependencies {
// Adding dependencies here will add the dependencies to each subproject.
testCompile group: 'junit', name: 'junit', version: '4.12'
testCompile group: 'org.mockito', name: 'mockito-core', version: '2.0.28-beta'
testCompile group: 'org.easytesting', name: 'fest-assert-core', version: '2.0M10'
deployerJars "org.apache.maven.wagon:wagon-ssh:2.9"
}
jar {
@ -111,3 +116,17 @@ artifacts {
archives writeFullPom.outputs.files[0]
}
uploadArchives {
repositories.mavenDeployer {
configuration = configurations.deployerJars
// disable this otherwise it will fill up the server with stale jars
uniqueVersion = false
repository(url: "scp://updates.jmonkeyengine.org/var/www/updates/maven") {
authentication(userName: "www-updater", privateKey: "private/www-updater.key")
}
pom.project pomConfig
}
}

@ -23,6 +23,9 @@ bulletUrl = https://storage.googleapis.com/google-code-archive-downloads/v2/code
bulletFolder = bullet-2.82-r2704
bulletZipFile = bullet.zip
# Path for downloading NetBeans Base
netbeansUrl = http://download.netbeans.org/netbeans/8.0.2/final/zip/netbeans-8.0.2-201411181905-javase.zip
# POM settings
POM_NAME=jMonkeyEngine
POM_DESCRIPTION=jMonkeyEngine is a 3D game engine for adventurous Java developers

@ -102,8 +102,7 @@ task copyJmeAndroid(type: Copy, dependsOn:copyJmeCpp) {
into outputDir
}
task generateNativeHeaders(dependsOn: copyJmeAndroid) {
doLast {
task generateNativeHeaders(dependsOn: copyJmeAndroid) << {
String destDirPath = jniPath
String classes = " \
com.jme3.bullet.PhysicsSpace, \
@ -155,7 +154,6 @@ task generateNativeHeaders(dependsOn: copyJmeAndroid) {
args classes.split(",").collect { it.trim() }
}
}
}
task buildBulletNativeLib(type: Exec, dependsOn: generateNativeHeaders) {
// args 'TARGET_PLATFORM=android-9'

@ -208,7 +208,7 @@ unzipBullet.dependsOn {
}
}
task unzipBulletIfNeeded {
task unzipBulletIfNeeded << {
}
unzipBulletIfNeeded.dependsOn {

@ -62,8 +62,7 @@ jar.doFirst{
task dist (dependsOn: ['build', ':jme3-jogl:jar', ':jme3-bullet:jar', ':jme3-android:jar', \
':jme3-android-native:jar', ':jme3-bullet-native-android:jar', \
':jme3-bullet-native:jar']) {
doLast {
':jme3-bullet-native:jar']) << {
// Copy all dependencies to ../dist/lib, remove versions from jar files
configurations.compile.resolvedConfiguration.resolvedArtifacts.each { artifact ->
copy {
@ -129,4 +128,3 @@ task dist (dependsOn: ['build', ':jme3-jogl:jar', ':jme3-bullet:jar', ':jme3-and
rename {project(':jme3-bullet-native-android').name+".jar"}
}
}
}

Binary file not shown.

@ -45,6 +45,7 @@ buildscript {
ext {
jmeRevision = 0
jmeNbmRevision = 0
jmeGitHash = ""
jmeGitTag = ""
jmeShortGitHash = ""
@ -52,6 +53,7 @@ ext {
jmeBranchName = "unknown"
jmeFullVersion = "${jmeVersion}-UNKNOWN"
jmePomVersion = "unknown"
jmeNbmUcSuffix = "unknown"
}
def getReleaseInfo(String tag) {
@ -131,6 +133,8 @@ task configureVersionInfo {
if (releaseInfo != null) {
jmeFullVersion = "${releaseInfo.baseVersion}${releaseInfo.releaseSuffix}"
jmePomVersion = "${releaseInfo.mainVersion}${releaseInfo.releaseSuffix}"
jmeNbmRevision = "0"
jmeNbmUcSuffix = "stable/${releaseInfo.baseVersion}/plugins"
} else {
// SNAPSHOT
jmeFullVersion = jmeMainVersion
@ -145,13 +149,20 @@ task configureVersionInfo {
if (jmeBranchName != "v3.1") {
jmeFullVersion += "-${jmeBranchName}"
jmePomVersion += "-${jmeBranchName}"
jmeNbmUcSuffix = "${jmeBranchName}-"
} else {
jmeNbmUcSuffix = ""
}
jmeNbmUcSuffix += "nightly/" + jmeMainVersion + "/plugins"
jmeFullVersion += "-${jmeRevision}"
jmePomVersion += "-SNAPSHOT"
jmeNbmRevision = jmeRevision
}
logger.warn("Full Version: ${jmeFullVersion}")
logger.warn("POM Version: ${jmePomVersion}")
logger.warn("NBM Revision: ${jmeNbmRevision}")
logger.warn("NBM UC Suffix: ${jmeNbmUcSuffix}")
} catch (ex) {
// Failed to get repo info
logger.warn("Failed to get repository info: " + ex.message + ". " + \

Loading…
Cancel
Save