Gradle build refactoring, closes #46
This commit is contained in:
parent
11d7002841
commit
eca77a0afc
81
build.gradle
81
build.gradle
@ -1,70 +1,39 @@
|
|||||||
buildscript {
|
buildscript {
|
||||||
repositories {
|
repositories {
|
||||||
mavenCentral()
|
jcenter()
|
||||||
mavenLocal()
|
}
|
||||||
}
|
dependencies {
|
||||||
|
classpath 'com.android.tools.build:gradle:2.1.2'
|
||||||
dependencies {
|
classpath 'com.github.dcendents:android-maven-gradle-plugin:1.3'
|
||||||
classpath 'org.gradle.api.plugins:gradle-nexus-plugin:0.3'
|
}
|
||||||
|
|
||||||
classpath 'com.android.tools.build:gradle:2.1.2'
|
|
||||||
|
|
||||||
// for aar/maven stuff
|
|
||||||
// https://github.com/dcendents/android-maven-gradle-plugin
|
|
||||||
classpath 'com.github.dcendents:android-maven-gradle-plugin:1.3'
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
def filterProjects(filter) {
|
|
||||||
return subprojects.findAll { project -> filter.contains(project.name) }
|
|
||||||
}
|
|
||||||
|
|
||||||
//apply from:'jdee.gradle'
|
|
||||||
|
|
||||||
allprojects {
|
allprojects {
|
||||||
group = 'org.oscim'
|
group = 'org.oscim'
|
||||||
version = '0.6.0-SNAPSHOT'
|
version = '0.6.0-SNAPSHOT'
|
||||||
|
|
||||||
ext.gdxVersion = "1.9.3"
|
ext.androidBuildVersionTools = "23.0.3"
|
||||||
ext.androidBuildVersionTools = "23.0.3"
|
ext.gdxVersion = "1.9.3"
|
||||||
|
|
||||||
repositories {
|
|
||||||
maven { url 'https://github.com/hjanetzek/maven-repo/raw/master/' }
|
|
||||||
mavenCentral()
|
|
||||||
// Jeo
|
|
||||||
// maven { url 'http://repo.boundlessgeo.com/main' }
|
|
||||||
mavenLocal()
|
|
||||||
// Local andoird repo
|
|
||||||
maven { url "${System.env.ANDROID_HOME}/extras/android/m2repository" }
|
|
||||||
}
|
|
||||||
|
|
||||||
// create IntelliJ project settings - untested
|
|
||||||
apply plugin: 'idea'
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
def androidCompileSdk() { return 23 }
|
||||||
|
|
||||||
def androidMinSdk() { return 10 }
|
def androidMinSdk() { return 10 }
|
||||||
def androidTargetSdk() { return 23 }
|
|
||||||
|
def androidTargetSdk() { return 22 }
|
||||||
|
|
||||||
def versionCode() { return 50 }
|
def versionCode() { return 50 }
|
||||||
|
|
||||||
def versionName() { return version }
|
def versionName() { return version }
|
||||||
|
|
||||||
subprojects {
|
subprojects {
|
||||||
// create eclipse project settings
|
repositories {
|
||||||
apply plugin: 'eclipse'
|
maven { url 'https://github.com/opensciencemap/maven-repo/raw/master/' }
|
||||||
|
jcenter()
|
||||||
|
}
|
||||||
|
|
||||||
task copySettings(type: Copy) {
|
tasks.withType(JavaCompile) {
|
||||||
from "$rootDir/eclipse"
|
sourceCompatibility = JavaVersion.VERSION_1_7
|
||||||
into ".settings"
|
targetCompatibility = JavaVersion.VERSION_1_7
|
||||||
include '**/*'
|
}
|
||||||
}
|
|
||||||
|
|
||||||
tasks.withType(JavaCompile) {
|
|
||||||
sourceCompatibility = JavaVersion.VERSION_1_7
|
|
||||||
targetCompatibility = JavaVersion.VERSION_1_7
|
|
||||||
}
|
|
||||||
|
|
||||||
eclipseProject.dependsOn copySettings
|
|
||||||
|
|
||||||
// create emacs JDEE project settings
|
|
||||||
// http://ignatyev-dev.blogspot.de/2013/07/gradle-projects-in-jdee.html
|
|
||||||
//apply from:'../jdee.gradle'
|
|
||||||
}
|
}
|
||||||
|
@ -1,16 +1,10 @@
|
|||||||
repositories {
|
|
||||||
maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
|
|
||||||
}
|
|
||||||
|
|
||||||
apply plugin: 'java'
|
apply plugin: 'java'
|
||||||
|
|
||||||
sourceSets {
|
|
||||||
main.java.srcDirs = ['src']
|
|
||||||
main.resources.srcDirs = ['src']
|
|
||||||
}
|
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
compile "com.badlogicgames.gdx:gdx-jnigen:$gdxVersion"
|
compile "com.badlogicgames.gdx:gdx-jnigen:$gdxVersion"
|
||||||
}
|
}
|
||||||
|
|
||||||
eclipse.project.name = 'vtm-jni'
|
sourceSets {
|
||||||
|
main.java.srcDirs = ['src']
|
||||||
|
main.resources.srcDirs = ['src']
|
||||||
|
}
|
||||||
|
@ -1,112 +1,59 @@
|
|||||||
apply plugin: 'com.android.application'
|
apply plugin: 'com.android.application'
|
||||||
|
|
||||||
configurations {
|
|
||||||
providedCompile
|
|
||||||
eclipseCompile
|
|
||||||
}
|
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
compile project(':vtm-android')
|
compile project(':vtm-android')
|
||||||
compile project(':vtm-jeo')
|
compile project(':vtm-extras')
|
||||||
compile project(':vtm-extras')
|
compile project(':vtm-jeo')
|
||||||
compile project(':vtm-themes')
|
compile project(':vtm-themes')
|
||||||
compile files("${rootDir}/vtm-android/vtm-natives-android.jar")
|
compile files("${rootDir}/vtm-android/vtm-natives-android.jar")
|
||||||
|
compile 'com.android.support:support-v4:24.0.0'
|
||||||
compile 'com.android.support:support-v4:22.+'
|
compile 'com.android.support:appcompat-v7:24.0.0'
|
||||||
compile 'com.android.support:appcompat-v7:22.+'
|
|
||||||
//eclipseCompile project(':appcompat')
|
|
||||||
|
|
||||||
compile 'com.noveogroup.android:android-logger:1.3.4'
|
|
||||||
}
|
}
|
||||||
|
|
||||||
android {
|
android {
|
||||||
compileSdkVersion androidTargetSdk()
|
compileSdkVersion androidCompileSdk()
|
||||||
buildToolsVersion "$androidBuildVersionTools"
|
buildToolsVersion "$androidBuildVersionTools"
|
||||||
|
|
||||||
sourceSets {
|
|
||||||
main {
|
|
||||||
manifest.srcFile 'AndroidManifest.xml'
|
|
||||||
java.srcDirs = ['src']
|
|
||||||
resources.srcDirs = ['src', 'assets']
|
|
||||||
res.srcDirs = ['res']
|
|
||||||
assets.srcDirs = ['assets']
|
|
||||||
}
|
|
||||||
|
|
||||||
compileOptions {
|
compileOptions {
|
||||||
sourceCompatibility JavaVersion.VERSION_1_7
|
sourceCompatibility JavaVersion.VERSION_1_7
|
||||||
targetCompatibility JavaVersion.VERSION_1_7
|
targetCompatibility JavaVersion.VERSION_1_7
|
||||||
}
|
}
|
||||||
|
|
||||||
debug.setRoot('build-types/debug')
|
defaultConfig {
|
||||||
release.setRoot('build-types/release')
|
versionCode versionCode()
|
||||||
}
|
versionName versionName()
|
||||||
// remove duplicates
|
minSdkVersion androidMinSdk()
|
||||||
packagingOptions {
|
|
||||||
exclude 'META-INF/services/org.jeo.data.Driver'
|
|
||||||
exclude 'META-INF/LICENSE'
|
|
||||||
exclude 'META-INF/NOTICE'
|
|
||||||
}
|
|
||||||
|
|
||||||
// ignore deprecated
|
|
||||||
lintOptions.abortOnError false
|
|
||||||
}
|
|
||||||
|
|
||||||
eclipse {
|
|
||||||
classpath {
|
|
||||||
plusConfigurations += [ configurations.compile, configurations.eclipseCompile ]
|
|
||||||
|
|
||||||
defaultOutputDir = file('bin/classes')
|
|
||||||
|
|
||||||
containers = ['com.android.ide.eclipse.adt.ANDROID_FRAMEWORK',
|
|
||||||
'com.android.ide.eclipse.adt.LIBRARIES',
|
|
||||||
'com.android.ide.eclipse.adt.DEPENDENCIES']
|
|
||||||
|
|
||||||
file {
|
|
||||||
// Manipulation of the classpath XML before merging local
|
|
||||||
// and generated copies
|
|
||||||
beforeMerged { classpath ->
|
|
||||||
// Remove all source entries to avoid overlap
|
|
||||||
classpath.entries.removeAll() { e ->
|
|
||||||
e.kind == 'src'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// only used to explode jni .so into aar
|
|
||||||
whenMerged {
|
|
||||||
classpath ->
|
|
||||||
classpath.entries.findAll { e ->
|
|
||||||
e.path.contains('ANDROID_FRAMEWORK')
|
|
||||||
}*.exported = false
|
|
||||||
classpath.entries.removeAll() { e ->
|
|
||||||
e.path.contains('support')
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Direct manipulation of the generated classpath XML
|
|
||||||
withXml {
|
|
||||||
def node = it.asNode()
|
|
||||||
node.appendNode('classpathentry kind="src" path="src"')
|
|
||||||
node.appendNode('classpathentry kind="src" path="gen"')
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
project {
|
|
||||||
natures = ['com.android.ide.eclipse.adt.AndroidNature',
|
|
||||||
'org.eclipse.jdt.core.javanature']
|
|
||||||
|
|
||||||
buildCommand 'com.android.ide.eclipse.adt.ResourceManagerBuilder'
|
sourceSets {
|
||||||
buildCommand 'com.android.ide.eclipse.adt.PreCompilerBuilder'
|
main {
|
||||||
buildCommand 'com.android.ide.eclipse.adt.ApkBuilder'
|
manifest.srcFile 'AndroidManifest.xml'
|
||||||
}
|
java.srcDirs = ['src']
|
||||||
|
resources.srcDirs = ['src', 'assets']
|
||||||
|
res.srcDirs = ['res']
|
||||||
|
assets.srcDirs = ['assets']
|
||||||
|
}
|
||||||
|
debug.setRoot('build-types/debug')
|
||||||
|
release.setRoot('build-types/release')
|
||||||
|
}
|
||||||
|
|
||||||
|
lintOptions { abortOnError false }
|
||||||
|
|
||||||
|
packagingOptions {
|
||||||
|
exclude 'META-INF/services/org.jeo.data.Driver'
|
||||||
|
exclude 'META-INF/LICENSE'
|
||||||
|
exclude 'META-INF/NOTICE'
|
||||||
|
}
|
||||||
}
|
}
|
||||||
task run (dependsOn: 'installDebug'){
|
|
||||||
doFirst {
|
task run(dependsOn: 'installDebug') {
|
||||||
println(">> adb run...")
|
doFirst {
|
||||||
String adb = System.getenv()['ANDROID_HOME'] + '/platform-tools/adb'
|
println(">> adb run...")
|
||||||
String cmd = "${adb} shell am start -n org.oscim.android.test/.Samples"
|
String adb = System.getenv()['ANDROID_HOME'] + '/platform-tools/adb'
|
||||||
def proc = cmd.execute()
|
String cmd = "${adb} shell am start -n org.oscim.android.test/.Samples"
|
||||||
proc.in.eachLine {line -> println line}
|
def proc = cmd.execute()
|
||||||
proc.err.eachLine {line -> System.err.println( 'ERROR: ' + line)}
|
proc.in.eachLine { line -> println line }
|
||||||
proc.waitFor()
|
proc.err.eachLine { line -> System.err.println('ERROR: ' + line) }
|
||||||
}
|
proc.waitFor()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,118 +1,53 @@
|
|||||||
apply plugin: 'com.android.application'
|
apply plugin: 'com.android.application'
|
||||||
|
|
||||||
configurations { providedCompile }
|
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
compile project(':vtm-gdx')
|
compile project(':vtm-gdx')
|
||||||
compile project(':vtm-themes')
|
compile project(':vtm-themes')
|
||||||
compile 'com.noveogroup.android:android-logger:1.3.4'
|
compile files("${rootDir}/vtm-android/vtm-natives-android.jar")
|
||||||
compile "com.badlogicgames.gdx:gdx-backend-android:$gdxVersion"
|
compile "com.badlogicgames.gdx:gdx-backend-android:$gdxVersion"
|
||||||
//compile "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-armeabi"
|
compile files('gdx-natives-android.jar')
|
||||||
//compile "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-armeabi-v7a"
|
|
||||||
//compile "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-x86"
|
|
||||||
compile files('gdx-natives-android.jar')
|
|
||||||
compile files("${rootDir}/vtm-android/vtm-natives-android.jar")
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//task copyLibs(type: Copy) {
|
|
||||||
// from "$rootDir/vtm-ext-libs/vtm-gdx-android"
|
|
||||||
// into "libs"
|
|
||||||
// include '**/*'
|
|
||||||
//}
|
|
||||||
|
|
||||||
//tasks.withType(JavaCompile) { compileTask ->
|
|
||||||
// compileTask.dependsOn copyLibs }
|
|
||||||
|
|
||||||
android {
|
android {
|
||||||
compileSdkVersion androidTargetSdk()
|
compileSdkVersion androidCompileSdk()
|
||||||
buildToolsVersion "$androidBuildVersionTools"
|
buildToolsVersion "$androidBuildVersionTools"
|
||||||
lintOptions { abortOnError false }
|
|
||||||
|
|
||||||
sourceSets {
|
|
||||||
main {
|
|
||||||
manifest.srcFile 'AndroidManifest.xml'
|
|
||||||
java.srcDirs = ['src', 'assets']
|
|
||||||
resources.srcDirs = ['src', 'assets']
|
|
||||||
aidl.srcDirs = ['src', 'assets']
|
|
||||||
renderscript.srcDirs = ['src', 'assets']
|
|
||||||
res.srcDirs = ['res']
|
|
||||||
assets.srcDirs = ['assets']
|
|
||||||
}
|
|
||||||
|
|
||||||
compileOptions {
|
compileOptions {
|
||||||
sourceCompatibility JavaVersion.VERSION_1_7
|
sourceCompatibility JavaVersion.VERSION_1_7
|
||||||
targetCompatibility JavaVersion.VERSION_1_7
|
targetCompatibility JavaVersion.VERSION_1_7
|
||||||
}
|
}
|
||||||
|
|
||||||
debug.setRoot('build-types/debug')
|
defaultConfig {
|
||||||
release.setRoot('build-types/release')
|
versionCode versionCode()
|
||||||
}
|
versionName versionName()
|
||||||
}
|
minSdkVersion androidMinSdk()
|
||||||
|
|
||||||
// Including configurations into Eclipse
|
|
||||||
eclipse {
|
|
||||||
|
|
||||||
// Configuring Eclipse classpath
|
|
||||||
classpath {
|
|
||||||
plusConfigurations += [ configurations.compile ]
|
|
||||||
|
|
||||||
defaultOutputDir = file('bin/classes')
|
|
||||||
|
|
||||||
containers = ['com.android.ide.eclipse.adt.ANDROID_FRAMEWORK',
|
|
||||||
'com.android.ide.eclipse.adt.LIBRARIES',
|
|
||||||
'com.android.ide.eclipse.adt.DEPENDENCIES']
|
|
||||||
|
|
||||||
file {
|
|
||||||
beforeMerged { classpath ->
|
|
||||||
// Remove all source entries to avoid overlap
|
|
||||||
classpath.entries.removeAll() { c ->
|
|
||||||
c.kind == 'src'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// only used to explode jni .so into aar
|
|
||||||
whenMerged { classpath ->
|
|
||||||
classpath.entries.findAll { entry ->
|
|
||||||
entry.path.contains('ANDROID_FRAMEWORK') ||
|
|
||||||
entry.path.contains('support') ||
|
|
||||||
entry.path.contains('native-libs')
|
|
||||||
}*.exported = false
|
|
||||||
|
|
||||||
classpath.entries.removeAll { entry ->
|
|
||||||
entry.path.contains('gdx-2') }
|
|
||||||
}
|
|
||||||
|
|
||||||
// Direct manipulation of the generated classpath XML
|
|
||||||
withXml {
|
|
||||||
def node = it.asNode()
|
|
||||||
node.appendNode('classpathentry kind="src" path="src"')
|
|
||||||
node.appendNode('classpathentry kind="src" path="gen"')
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
project {
|
sourceSets {
|
||||||
natures = ['com.android.ide.eclipse.adt.AndroidNature',
|
main {
|
||||||
'org.eclipse.jdt.core.javanature']
|
manifest.srcFile 'AndroidManifest.xml'
|
||||||
|
java.srcDirs = ['src']
|
||||||
|
resources.srcDirs = ['src', 'assets']
|
||||||
|
aidl.srcDirs = ['src', 'assets']
|
||||||
|
renderscript.srcDirs = ['src', 'assets']
|
||||||
|
res.srcDirs = ['res']
|
||||||
|
assets.srcDirs = ['assets']
|
||||||
|
}
|
||||||
|
debug.setRoot('build-types/debug')
|
||||||
|
release.setRoot('build-types/release')
|
||||||
|
}
|
||||||
|
|
||||||
buildCommand 'com.android.ide.eclipse.adt.ResourceManagerBuilder'
|
lintOptions { abortOnError false }
|
||||||
buildCommand 'com.android.ide.eclipse.adt.PreCompilerBuilder'
|
|
||||||
buildCommand 'com.android.ide.eclipse.adt.ApkBuilder'
|
|
||||||
// use extracted jni .so in eclipse
|
|
||||||
linkedResource name: 'libs', type: '2',
|
|
||||||
locationUri: 'PARENT-1-PROJECT_LOC/vtm-ext-libs/vtm-gdx-android'
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
task run (dependsOn: 'installDebug'){
|
task run(dependsOn: 'installDebug') {
|
||||||
doFirst {
|
doFirst {
|
||||||
println(">> adb run...")
|
println(">> adb run...")
|
||||||
String adb = System.getenv()['ANDROID_HOME'] + '/platform-tools/adb'
|
String adb = System.getenv()['ANDROID_HOME'] + '/platform-tools/adb'
|
||||||
String cmd = "${adb} shell am start -n org.oscim.gdx/.MainActivity"
|
String cmd = "${adb} shell am start -n org.oscim.gdx/.MainActivity"
|
||||||
def proc = cmd.execute()
|
def proc = cmd.execute()
|
||||||
proc.in.eachLine {line -> println line}
|
proc.in.eachLine { line -> println line }
|
||||||
proc.err.eachLine {line -> System.err.println( 'ERROR: ' + line)}
|
proc.err.eachLine { line -> System.err.println('ERROR: ' + line) }
|
||||||
proc.waitFor()
|
proc.waitFor()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,108 +1,51 @@
|
|||||||
apply plugin: 'com.android.application'
|
apply plugin: 'com.android.application'
|
||||||
|
|
||||||
configurations {
|
|
||||||
providedCompile
|
|
||||||
eclipseCompile
|
|
||||||
}
|
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
compile project(':vtm-android')
|
compile project(':vtm-android')
|
||||||
compile project(':vtm-themes')
|
compile project(':vtm-themes')
|
||||||
compile files("${rootDir}/vtm-android/vtm-natives-android.jar")
|
compile files("${rootDir}/vtm-android/vtm-natives-android.jar")
|
||||||
|
compile 'com.android.support:support-v4:24.0.0'
|
||||||
compile 'com.android.support:support-v4:22.+'
|
compile 'com.android.support:appcompat-v7:24.0.0'
|
||||||
compile 'com.android.support:appcompat-v7:22.+'
|
|
||||||
//eclipseCompile project(':appcompat')
|
|
||||||
|
|
||||||
compile 'com.noveogroup.android:android-logger:1.3.4'
|
|
||||||
}
|
}
|
||||||
|
|
||||||
android {
|
android {
|
||||||
compileSdkVersion androidTargetSdk()
|
compileSdkVersion androidCompileSdk()
|
||||||
buildToolsVersion "$androidBuildVersionTools"
|
buildToolsVersion "$androidBuildVersionTools"
|
||||||
|
|
||||||
sourceSets {
|
|
||||||
main {
|
|
||||||
manifest.srcFile 'AndroidManifest.xml'
|
|
||||||
java.srcDirs = ['src']
|
|
||||||
resources.srcDirs = ['src', 'assets']
|
|
||||||
res.srcDirs = ['res']
|
|
||||||
assets.srcDirs = ['assets']
|
|
||||||
}
|
|
||||||
|
|
||||||
compileOptions {
|
compileOptions {
|
||||||
sourceCompatibility JavaVersion.VERSION_1_7
|
sourceCompatibility JavaVersion.VERSION_1_7
|
||||||
targetCompatibility JavaVersion.VERSION_1_7
|
targetCompatibility JavaVersion.VERSION_1_7
|
||||||
}
|
}
|
||||||
|
|
||||||
debug.setRoot('build-types/debug')
|
defaultConfig {
|
||||||
release.setRoot('build-types/release')
|
versionCode versionCode()
|
||||||
}
|
versionName versionName()
|
||||||
|
minSdkVersion androidMinSdk()
|
||||||
// ignore deprecated
|
|
||||||
lintOptions.abortOnError false
|
|
||||||
}
|
|
||||||
|
|
||||||
//Including configurations into Eclipse
|
|
||||||
eclipse {
|
|
||||||
|
|
||||||
// Configuring Eclipse classpath
|
|
||||||
classpath {
|
|
||||||
plusConfigurations += [ configurations.compile, configurations.eclipseCompile ]
|
|
||||||
|
|
||||||
defaultOutputDir = file('bin/classes')
|
|
||||||
|
|
||||||
containers = ['com.android.ide.eclipse.adt.ANDROID_FRAMEWORK',
|
|
||||||
'com.android.ide.eclipse.adt.LIBRARIES',
|
|
||||||
'com.android.ide.eclipse.adt.DEPENDENCIES']
|
|
||||||
|
|
||||||
file {
|
|
||||||
// Manipulation of the classpath XML before merging local
|
|
||||||
// and generated copies
|
|
||||||
beforeMerged { classpath ->
|
|
||||||
// Remove all source entries to avoid overlap
|
|
||||||
classpath.entries.removeAll() { e ->
|
|
||||||
e.kind == 'src'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// only used to explode jni .so into aar
|
|
||||||
whenMerged {
|
|
||||||
classpath ->
|
|
||||||
classpath.entries.findAll { e ->
|
|
||||||
e.path.contains('ANDROID_FRAMEWORK')
|
|
||||||
}*.exported = false
|
|
||||||
classpath.entries.removeAll() { e ->
|
|
||||||
e.path.contains('support')
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Direct manipulation of the generated classpath XML
|
|
||||||
withXml {
|
|
||||||
def node = it.asNode()
|
|
||||||
node.appendNode('classpathentry kind="src" path="src"')
|
|
||||||
node.appendNode('classpathentry kind="src" path="gen"')
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
project {
|
sourceSets {
|
||||||
natures = ['com.android.ide.eclipse.adt.AndroidNature',
|
main {
|
||||||
'org.eclipse.jdt.core.javanature']
|
manifest.srcFile 'AndroidManifest.xml'
|
||||||
buildCommand 'com.android.ide.eclipse.adt.ResourceManagerBuilder'
|
java.srcDirs = ['src']
|
||||||
buildCommand 'com.android.ide.eclipse.adt.PreCompilerBuilder'
|
resources.srcDirs = ['src', 'assets']
|
||||||
buildCommand 'com.android.ide.eclipse.adt.ApkBuilder'
|
res.srcDirs = ['res']
|
||||||
}
|
assets.srcDirs = ['assets']
|
||||||
|
}
|
||||||
|
debug.setRoot('build-types/debug')
|
||||||
|
release.setRoot('build-types/release')
|
||||||
|
}
|
||||||
|
|
||||||
|
lintOptions { abortOnError false }
|
||||||
}
|
}
|
||||||
|
|
||||||
task run (dependsOn: 'installDebug'){
|
task run(dependsOn: 'installDebug') {
|
||||||
doFirst {
|
doFirst {
|
||||||
println(">> adb run <<")
|
println(">> adb run <<")
|
||||||
String adb = System.getenv()['ANDROID_HOME'] + '/platform-tools/adb'
|
String adb = System.getenv()['ANDROID_HOME'] + '/platform-tools/adb'
|
||||||
String cmd = "${adb} shell am start -n org.oscim.android.start/.TestActivity"
|
String cmd = "${adb} shell am start -n org.oscim.android.start/.TestActivity"
|
||||||
def proc = cmd.execute()
|
def proc = cmd.execute()
|
||||||
proc.in.eachLine {line -> println line}
|
proc.in.eachLine { line -> println line }
|
||||||
proc.err.eachLine {line -> System.err.println( 'ERROR: ' + line)}
|
proc.err.eachLine { line -> System.err.println('ERROR: ' + line) }
|
||||||
proc.waitFor()
|
proc.waitFor()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,94 +1,38 @@
|
|||||||
apply plugin: 'com.android.library'
|
apply plugin: 'com.android.library'
|
||||||
apply plugin: 'com.github.dcendents.android-maven'
|
apply plugin: 'com.github.dcendents.android-maven'
|
||||||
|
|
||||||
configurations {
|
|
||||||
eclipseCompile
|
|
||||||
}
|
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
compile project(':vtm')
|
compile project(':vtm')
|
||||||
provided files('vtm-natives-android.jar')
|
|
||||||
|
|
||||||
compile 'com.android.support:support-v4:21.+'
|
|
||||||
//eclipseCompile project(':appcompat')
|
|
||||||
}
|
}
|
||||||
|
|
||||||
android {
|
android {
|
||||||
compileSdkVersion androidTargetSdk()
|
compileSdkVersion androidCompileSdk()
|
||||||
buildToolsVersion = "$androidBuildVersionTools"
|
buildToolsVersion = "$androidBuildVersionTools"
|
||||||
|
|
||||||
sourceSets {
|
compileOptions {
|
||||||
main {
|
sourceCompatibility JavaVersion.VERSION_1_7
|
||||||
manifest.srcFile 'AndroidManifest.xml'
|
targetCompatibility JavaVersion.VERSION_1_7
|
||||||
java.srcDirs = ['src']
|
|
||||||
resources.srcDirs = ['src']
|
|
||||||
res.srcDirs = ['res']
|
|
||||||
assets.srcDirs = ['assets']
|
|
||||||
}
|
}
|
||||||
debug.setRoot('build-types/debug')
|
|
||||||
release.setRoot('build-types/release')
|
|
||||||
}
|
|
||||||
|
|
||||||
lintOptions.abortOnError false
|
defaultConfig {
|
||||||
}
|
versionCode versionCode()
|
||||||
|
versionName versionName()
|
||||||
eclipse {
|
minSdkVersion androidMinSdk()
|
||||||
classpath {
|
|
||||||
plusConfigurations += [ configurations.compile, configurations.eclipseCompile ]
|
|
||||||
|
|
||||||
//noExportConfigurations += [ configurations.provided ]
|
|
||||||
|
|
||||||
//customizing the classes output directory:
|
|
||||||
defaultOutputDir = file('bin/classes')
|
|
||||||
|
|
||||||
containers = ['com.android.ide.eclipse.adt.ANDROID_FRAMEWORK',
|
|
||||||
'com.android.ide.eclipse.adt.LIBRARIES',
|
|
||||||
'com.android.ide.eclipse.adt.DEPENDENCIES']
|
|
||||||
|
|
||||||
file {
|
|
||||||
// Manipulation of the classpath XML before merging local
|
|
||||||
// and generated copies
|
|
||||||
beforeMerged { classpath ->
|
|
||||||
// Remove all source entries to avoid overlap
|
|
||||||
classpath.entries.removeAll() { e ->
|
|
||||||
e.kind == 'src'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// only used to explode jni .so into aar
|
|
||||||
whenMerged {
|
|
||||||
classpath ->
|
|
||||||
classpath.entries.findAll { e ->
|
|
||||||
e.path.contains('native-libs') ||
|
|
||||||
e.path.contains('ANDROID_FRAMEWORK')
|
|
||||||
}*.exported = false
|
|
||||||
classpath.entries.removeAll() { e ->
|
|
||||||
e.path.contains('support')
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Direct manipulation of the generated classpath XML
|
|
||||||
withXml {
|
|
||||||
// Since non-default source directories are used
|
|
||||||
// they need to be manually added to the classpath XML
|
|
||||||
def node = it.asNode()
|
|
||||||
// Main source directory and generated code directory
|
|
||||||
node.appendNode('classpathentry kind="src" path="src"')
|
|
||||||
node.appendNode('classpathentry kind="src" path="gen"')
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
project {
|
|
||||||
natures = ['com.android.ide.eclipse.adt.AndroidNature',
|
|
||||||
'org.eclipse.jdt.core.javanature']
|
|
||||||
buildCommand 'com.android.ide.eclipse.adt.ResourceManagerBuilder'
|
|
||||||
buildCommand 'com.android.ide.eclipse.adt.PreCompilerBuilder'
|
|
||||||
buildCommand 'com.android.ide.eclipse.adt.ApkBuilder'
|
|
||||||
|
|
||||||
// use extracted jni .so in eclipse
|
sourceSets {
|
||||||
linkedResource name: 'libs', type: '2',
|
main {
|
||||||
locationUri: 'PARENT-1-PROJECT_LOC/vtm-ext-libs/vtm-android'
|
manifest.srcFile 'AndroidManifest.xml'
|
||||||
}
|
java.srcDirs = ['src']
|
||||||
|
resources.srcDirs = ['src']
|
||||||
|
res.srcDirs = ['res']
|
||||||
|
assets.srcDirs = ['assets']
|
||||||
|
}
|
||||||
|
debug.setRoot('build-types/debug')
|
||||||
|
release.setRoot('build-types/release')
|
||||||
|
}
|
||||||
|
|
||||||
|
lintOptions { abortOnError false }
|
||||||
}
|
}
|
||||||
|
|
||||||
android.libraryVariants.all { variant ->
|
android.libraryVariants.all { variant ->
|
||||||
|
@ -1,40 +1,23 @@
|
|||||||
repositories {
|
|
||||||
// libgdx
|
|
||||||
maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
|
|
||||||
}
|
|
||||||
|
|
||||||
apply plugin: 'java'
|
apply plugin: 'java'
|
||||||
apply plugin: 'maven'
|
apply plugin: 'maven'
|
||||||
apply plugin: 'application'
|
apply plugin: 'application'
|
||||||
|
|
||||||
mainClassName = 'org.oscim.gdx.GdxMapApp'
|
dependencies {
|
||||||
|
compile project(':vtm-gdx')
|
||||||
// package vtm native libs into jar
|
compile project(':vtm-themes')
|
||||||
//task copyLibs(type: Copy) {
|
compile files('vtm-natives-desktop.jar')
|
||||||
// from(zipTree("../vtm-ext-libs/gdx/vtm-jni-natives.jar"))
|
compile "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-desktop"
|
||||||
// into("${buildDir}/assets")
|
compile "com.badlogicgames.gdx:gdx-backend-jglfw:$gdxVersion"
|
||||||
//}
|
compile 'org.slf4j:slf4j-simple:1.7.21'
|
||||||
|
|
||||||
//tasks.withType(JavaCompile) { compileTask ->
|
|
||||||
// compileTask.dependsOn copyLibs
|
|
||||||
//}
|
|
||||||
|
|
||||||
sourceSets {
|
|
||||||
main {
|
|
||||||
java.srcDirs = ['src']
|
|
||||||
//main.resources.srcDirs = ["${buildDir}/assets"]
|
|
||||||
output.resourcesDir = 'assets'
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
mainClassName = 'org.oscim.gdx.GdxMapApp'
|
||||||
compile project(':vtm-gdx')
|
|
||||||
compile project(':vtm-themes')
|
sourceSets {
|
||||||
//compile "com.badlogicgames.gdx:gdx-backend-lwjgl:$gdxVersion"
|
main {
|
||||||
compile "com.badlogicgames.gdx:gdx-backend-jglfw:$gdxVersion"
|
java.srcDirs = ['src']
|
||||||
compile "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-desktop"
|
output.resourcesDir = 'assets'
|
||||||
compile 'org.slf4j:slf4j-simple:1.7.6'
|
}
|
||||||
compile files('vtm-natives-desktop.jar')
|
|
||||||
}
|
}
|
||||||
|
|
||||||
run { ignoreExitValue = true }
|
run { ignoreExitValue = true }
|
||||||
|
@ -1,16 +1,15 @@
|
|||||||
apply plugin: 'java'
|
apply plugin: 'java'
|
||||||
apply plugin: 'maven'
|
apply plugin: 'maven'
|
||||||
|
|
||||||
sourceSets {
|
|
||||||
main.java.srcDirs = ['src']
|
|
||||||
main.resources.srcDirs = ['src']
|
|
||||||
}
|
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
compile project(':vtm')
|
compile project(':vtm')
|
||||||
compile 'com.google.protobuf:protobuf-java:2.4.1'
|
compile 'com.fasterxml.jackson.core:jackson-core:2.3.0'
|
||||||
compile 'org.openstreetmap.osmosis:osmosis-osm-binary:0.43.1'
|
compile 'com.google.protobuf:protobuf-java:2.4.1'
|
||||||
compile 'com.fasterxml.jackson.core:jackson-core:2.3.0'
|
compile 'com.vividsolutions:jts:1.13'
|
||||||
compile 'com.vividsolutions:jts:1.13'
|
compile 'org.openstreetmap.osmosis:osmosis-osm-binary:0.44.1'
|
||||||
}
|
}
|
||||||
|
|
||||||
|
sourceSets {
|
||||||
|
main.java.srcDirs = ['src']
|
||||||
|
main.resources.srcDirs = ['src']
|
||||||
|
}
|
||||||
|
@ -1,17 +1,13 @@
|
|||||||
repositories {
|
|
||||||
maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
|
|
||||||
}
|
|
||||||
|
|
||||||
apply plugin: 'java'
|
apply plugin: 'java'
|
||||||
apply plugin: 'maven'
|
apply plugin: 'maven'
|
||||||
|
|
||||||
sourceSets {
|
dependencies {
|
||||||
main.java.srcDirs = ['src']
|
compile project(':vtm')
|
||||||
main.resources.srcDirs = ['src']
|
compile project(':vtm-themes')
|
||||||
|
compile "com.badlogicgames.gdx:gdx:$gdxVersion"
|
||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
sourceSets {
|
||||||
compile project(':vtm')
|
main.java.srcDirs = ['src']
|
||||||
compile project(':vtm-themes')
|
main.resources.srcDirs = ['src']
|
||||||
compile "com.badlogicgames.gdx:gdx:$gdxVersion"
|
|
||||||
}
|
}
|
||||||
|
@ -1,17 +1,14 @@
|
|||||||
buildscript {
|
buildscript {
|
||||||
repositories {
|
repositories {
|
||||||
mavenLocal()
|
jcenter()
|
||||||
mavenCentral()
|
}
|
||||||
maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
|
dependencies {
|
||||||
jcenter()
|
classpath 'com.mobidevelop.robovm:robovm-gradle-plugin:2.1.0'
|
||||||
}
|
}
|
||||||
dependencies {
|
|
||||||
classpath 'com.mobidevelop.robovm:robovm-gradle-plugin:2.1.0'
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
apply plugin: "java"
|
apply plugin: 'java'
|
||||||
apply plugin: "robovm"
|
apply plugin: 'robovm'
|
||||||
|
|
||||||
sourceSets.main.java.srcDirs = ["src/"]
|
sourceSets.main.java.srcDirs = ["src/"]
|
||||||
|
|
||||||
@ -19,9 +16,9 @@ sourceCompatibility = '1.7'
|
|||||||
[compileJava, compileTestJava]*.options*.encoding = 'UTF-8'
|
[compileJava, compileTestJava]*.options*.encoding = 'UTF-8'
|
||||||
|
|
||||||
ext {
|
ext {
|
||||||
// Configure your application main class
|
// Configure your application main class
|
||||||
mainClassName = "org.oscim.ios.RoboVmLauncher"
|
mainClassName = "org.oscim.ios.RoboVmLauncher"
|
||||||
roboVMVersion = "2.1.0"
|
roboVMVersion = "2.1.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
launchIPhoneSimulator.dependsOn build
|
launchIPhoneSimulator.dependsOn build
|
||||||
@ -30,43 +27,39 @@ launchIOSDevice.dependsOn build
|
|||||||
createIPA.dependsOn build
|
createIPA.dependsOn build
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
compile project(':vtm')
|
compile project(':vtm')
|
||||||
compile project(':vtm-gdx')
|
compile project(':vtm-gdx')
|
||||||
compile project(':vtm-themes')
|
compile project(':vtm-themes')
|
||||||
compile 'org.slf4j:slf4j-simple:1.7.5'
|
compile 'org.slf4j:slf4j-simple:1.7.21'
|
||||||
compile "com.mobidevelop.robovm:robovm-rt:$roboVMVersion"
|
compile "com.mobidevelop.robovm:robovm-rt:$roboVMVersion"
|
||||||
compile "com.mobidevelop.robovm:robovm-cocoatouch:$roboVMVersion"
|
compile "com.mobidevelop.robovm:robovm-cocoatouch:$roboVMVersion"
|
||||||
compile "com.badlogicgames.gdx:gdx-backend-robovm:$gdxVersion"
|
compile "com.badlogicgames.gdx:gdx-backend-robovm:$gdxVersion"
|
||||||
compile "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-ios"
|
compile "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-ios"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
task copyLibs(type: Copy) {
|
||||||
|
from(zipTree("vtm-natives-ios.jar"))
|
||||||
|
into("${buildDir}/natives")
|
||||||
|
|
||||||
task copyLibs(type: Copy){
|
|
||||||
from (zipTree("vtm-natives-ios.jar"))
|
|
||||||
into ("${buildDir}/natives")
|
|
||||||
}
|
}
|
||||||
|
|
||||||
task copyVtmResources(type: Copy){
|
task copyVtmResources(type: Copy) {
|
||||||
from ("../vtm/resources")
|
from("../vtm/resources")
|
||||||
into ("${buildDir}")
|
into("${buildDir}")
|
||||||
}
|
}
|
||||||
|
|
||||||
task copyVtmThemesResources(type: Copy){
|
task copyVtmThemesResources(type: Copy) {
|
||||||
from ("../vtm-themes/resources")
|
from("../vtm-themes/resources")
|
||||||
into ("${buildDir}")
|
into("${buildDir}")
|
||||||
}
|
}
|
||||||
|
|
||||||
tasks.withType(org.gradle.api.tasks.compile.JavaCompile){
|
tasks.withType(org.gradle.api.tasks.compile.JavaCompile) {
|
||||||
compileTask -> compileTask.dependsOn copyLibs
|
compileTask -> compileTask.dependsOn copyLibs
|
||||||
}
|
}
|
||||||
|
|
||||||
tasks.withType(org.gradle.api.tasks.compile.JavaCompile){
|
tasks.withType(org.gradle.api.tasks.compile.JavaCompile) {
|
||||||
compileTask -> compileTask.dependsOn copyVtmResources
|
compileTask -> compileTask.dependsOn copyVtmResources
|
||||||
}
|
}
|
||||||
|
|
||||||
tasks.withType(org.gradle.api.tasks.compile.JavaCompile){
|
tasks.withType(org.gradle.api.tasks.compile.JavaCompile) {
|
||||||
compileTask -> compileTask.dependsOn copyVtmThemesResources
|
compileTask -> compileTask.dependsOn copyVtmThemesResources
|
||||||
}
|
}
|
||||||
|
@ -1,23 +1,17 @@
|
|||||||
apply plugin: 'java'
|
apply plugin: 'java'
|
||||||
apply plugin: 'maven'
|
apply plugin: 'maven'
|
||||||
|
|
||||||
|
dependencies {
|
||||||
|
compile project(':vtm')
|
||||||
|
compile('org.jeo:jeo:0-SNAPSHOT') {
|
||||||
|
exclude group: 'org.slf4j', module: 'slf4j-jdk14'
|
||||||
|
}
|
||||||
|
compile('org.jeo:jeo-carto:0-SNAPSHOT') {
|
||||||
|
exclude group: 'org.slf4j', module: 'slf4j-jdk14'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
sourceSets {
|
sourceSets {
|
||||||
main.java.srcDirs = ['src']
|
main.java.srcDirs = ['src']
|
||||||
main.resources.srcDirs = ['src']
|
main.resources.srcDirs = ['src']
|
||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
|
||||||
compile project(':vtm')
|
|
||||||
compile ('org.jeo:jeo:0-SNAPSHOT') {
|
|
||||||
exclude group: 'org.slf4j', module: 'slf4j-jdk14'
|
|
||||||
}
|
|
||||||
compile ('org.jeo:jeo-carto:0-SNAPSHOT') {
|
|
||||||
exclude group: 'org.slf4j', module: 'slf4j-jdk14'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// eclipse.classpath.file.whenMerged { classpath ->
|
|
||||||
// classpath.entries.findAll { entry ->
|
|
||||||
// entry.path.contains('vtm-0.5.9-SNAPSHOT.jar') }*.exported = false
|
|
||||||
// }
|
|
||||||
|
@ -1,34 +1,19 @@
|
|||||||
repositories {
|
|
||||||
// libgdx
|
|
||||||
maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
|
|
||||||
}
|
|
||||||
|
|
||||||
apply plugin: 'java'
|
apply plugin: 'java'
|
||||||
apply plugin: 'application'
|
apply plugin: 'application'
|
||||||
|
|
||||||
|
dependencies {
|
||||||
|
compile project(':vtm-desktop')
|
||||||
|
compile project(':vtm-extras')
|
||||||
|
compile project(':vtm-jeo')
|
||||||
|
}
|
||||||
|
|
||||||
mainClassName = 'org.oscim.gdx.GdxMapApp'
|
mainClassName = 'org.oscim.gdx.GdxMapApp'
|
||||||
|
|
||||||
// package vtm native libs into jar
|
|
||||||
task copyLibs(type: Copy) {
|
|
||||||
from(zipTree("../vtm-desktop/vtm-natives-desktop.jar"))
|
|
||||||
into("${buildDir}/assets")
|
|
||||||
}
|
|
||||||
|
|
||||||
tasks.withType(JavaCompile) { compileTask ->
|
|
||||||
compileTask.dependsOn copyLibs
|
|
||||||
}
|
|
||||||
|
|
||||||
sourceSets {
|
sourceSets {
|
||||||
main {
|
main {
|
||||||
java.srcDirs = ['src']
|
java.srcDirs = ['src']
|
||||||
resources.srcDirs = ["${buildDir}/assets"]
|
resources.srcDirs = ["${buildDir}/assets"]
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
dependencies {
|
|
||||||
compile project(':vtm-desktop')
|
|
||||||
compile project(':vtm-extras')
|
|
||||||
compile project(':vtm-jeo')
|
|
||||||
}
|
}
|
||||||
|
|
||||||
run { ignoreExitValue = true }
|
run { ignoreExitValue = true }
|
||||||
|
@ -1,15 +1,15 @@
|
|||||||
apply plugin: 'java'
|
apply plugin: 'java'
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
compile project(':vtm')
|
compile project(':vtm')
|
||||||
compile 'com.squareup.okhttp:okhttp:1.5.2'
|
compile 'com.squareup.okhttp:okhttp:1.5.2'
|
||||||
testCompile 'junit:junit:4.11'
|
testCompile 'com.squareup.okhttp:mockwebserver:1.5.2'
|
||||||
testCompile 'org.mockito:mockito-all:1.9.5'
|
testCompile 'junit:junit:4.11'
|
||||||
testCompile 'org.easytesting:fest-assert-core:2.0M10'
|
testCompile 'org.easytesting:fest-assert-core:2.0M10'
|
||||||
testCompile 'com.squareup.okhttp:mockwebserver:1.5.2'
|
testCompile 'org.mockito:mockito-all:1.9.5'
|
||||||
}
|
}
|
||||||
|
|
||||||
sourceSets {
|
sourceSets {
|
||||||
main.java.srcDirs = ['src']
|
main.java.srcDirs = ['src']
|
||||||
test.java.srcDirs = ['test']
|
test.java.srcDirs = ['test']
|
||||||
}
|
}
|
||||||
|
@ -1,12 +1,11 @@
|
|||||||
apply plugin: 'java'
|
apply plugin: 'java'
|
||||||
apply plugin: 'maven'
|
apply plugin: 'maven'
|
||||||
|
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
compile project(':vtm')
|
compile project(':vtm')
|
||||||
}
|
}
|
||||||
|
|
||||||
sourceSets {
|
sourceSets {
|
||||||
main.java.srcDirs = ['src']
|
main.java.srcDirs = ['src']
|
||||||
main.resources.srcDirs = ['resources']
|
main.resources.srcDirs = ['resources']
|
||||||
}
|
}
|
||||||
|
@ -1,35 +1,34 @@
|
|||||||
buildscript {
|
buildscript {
|
||||||
repositories {
|
repositories {
|
||||||
mavenLocal()
|
mavenLocal()
|
||||||
mavenCentral()
|
mavenCentral()
|
||||||
maven { url 'http://dl.bintray.com/steffenschaefer/maven' }
|
maven { url 'http://dl.bintray.com/steffenschaefer/maven' }
|
||||||
}
|
}
|
||||||
dependencies {
|
dependencies {
|
||||||
classpath 'de.richsource.gradle.plugins:gwt-gradle-plugin:0.5'
|
classpath 'de.richsource.gradle.plugins:gwt-gradle-plugin:0.5'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
repositories {
|
repositories {
|
||||||
maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
|
maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
|
||||||
}
|
}
|
||||||
|
|
||||||
apply plugin: 'war'
|
apply plugin: 'war'
|
||||||
apply plugin: 'jetty'
|
apply plugin: 'jetty'
|
||||||
apply plugin: 'gwt'
|
apply plugin: 'gwt'
|
||||||
apply plugin: 'eclipse'
|
|
||||||
|
|
||||||
sourceSets {
|
sourceSets {
|
||||||
//main.java.srcDirs = ['src', 'src/org/oscim/gdx/emu']
|
//main.java.srcDirs = ['src', 'src/org/oscim/gdx/emu']
|
||||||
main.java.srcDirs = ['src']
|
main.java.srcDirs = ['src']
|
||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
providedCompile project(':vtm-web')
|
providedCompile project(':vtm-web')
|
||||||
providedCompile "com.badlogicgames.gdx:gdx:$gdxVersion:sources"
|
providedCompile "com.badlogicgames.gdx:gdx:$gdxVersion:sources"
|
||||||
providedCompile "com.badlogicgames.gdx:gdx-backend-gwt:$gdxVersion:sources"
|
providedCompile "com.badlogicgames.gdx:gdx-backend-gwt:$gdxVersion:sources"
|
||||||
providedCompile "com.badlogicgames.gdx:gdx-backend-gwt:$gdxVersion"
|
providedCompile "com.badlogicgames.gdx:gdx-backend-gwt:$gdxVersion"
|
||||||
providedCompile 'ru.finam:slf4j-gwt:1.2.1'
|
providedCompile 'ru.finam:slf4j-gwt:1.2.1'
|
||||||
providedCompile 'org.slf4j:slf4j-api:1.7.5'
|
providedCompile 'org.slf4j:slf4j-api:1.7.5'
|
||||||
}
|
}
|
||||||
|
|
||||||
// explicit dependencies for org.gradle.configureondemand=true
|
// explicit dependencies for org.gradle.configureondemand=true
|
||||||
@ -38,33 +37,32 @@ evaluationDependsOn(':vtm-themes')
|
|||||||
evaluationDependsOn(':vtm-gdx')
|
evaluationDependsOn(':vtm-gdx')
|
||||||
evaluationDependsOn(':vtm-web')
|
evaluationDependsOn(':vtm-web')
|
||||||
|
|
||||||
|
|
||||||
gwt {
|
gwt {
|
||||||
gwtVersion='2.6.1'
|
gwtVersion = '2.6.1'
|
||||||
modules 'org.oscim.web.VtmWebApp'
|
modules 'org.oscim.web.VtmWebApp'
|
||||||
|
|
||||||
superDev {
|
superDev {
|
||||||
noPrecompile=true
|
noPrecompile = true
|
||||||
}
|
}
|
||||||
compiler {
|
compiler {
|
||||||
enableClosureCompiler = false; // activates -XenableClosureCompiler
|
enableClosureCompiler = false; // activates -XenableClosureCompiler
|
||||||
disableClassMetadata = true; // activates -XdisableClassMetadata
|
disableClassMetadata = true; // activates -XdisableClassMetadata
|
||||||
disableCastChecking = true; // activates -XdisableCastChecking
|
disableCastChecking = true; // activates -XdisableCastChecking
|
||||||
}
|
}
|
||||||
|
|
||||||
src += files(sourceSets.main.java.srcDirs)
|
src += files(sourceSets.main.java.srcDirs)
|
||||||
src += files(project(':vtm').sourceSets.main.allJava.srcDirs)
|
src += files(project(':vtm').sourceSets.main.allJava.srcDirs)
|
||||||
src += files(project(':vtm-themes').sourceSets.main.allJava.srcDirs)
|
src += files(project(':vtm-themes').sourceSets.main.allJava.srcDirs)
|
||||||
src += files(project(':vtm-themes').sourceSets.main.resources.srcDirs)
|
src += files(project(':vtm-themes').sourceSets.main.resources.srcDirs)
|
||||||
src += files(project(':vtm-gdx').sourceSets.main.allJava.srcDirs)
|
src += files(project(':vtm-gdx').sourceSets.main.allJava.srcDirs)
|
||||||
src += files(project(':vtm-web').sourceSets.main.allJava.srcDirs)
|
src += files(project(':vtm-web').sourceSets.main.allJava.srcDirs)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Run jetty with draft compiled war
|
// Run jetty with draft compiled war
|
||||||
task jettyDraftWar(type: JettyRunWar) {
|
task jettyDraftWar(type: JettyRunWar) {
|
||||||
dependsOn draftWar
|
dependsOn draftWar
|
||||||
dependsOn.remove('war')
|
dependsOn.remove('war')
|
||||||
webApp=draftWar.archivePath
|
webApp = draftWar.archivePath
|
||||||
}
|
}
|
||||||
|
|
||||||
task copyThemeAssets(type: Copy) {
|
task copyThemeAssets(type: Copy) {
|
||||||
@ -86,20 +84,7 @@ task copyWarSources(type: Copy) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
tasks.withType(JavaCompile) { compileTask ->
|
tasks.withType(JavaCompile) { compileTask ->
|
||||||
compileTask.dependsOn copyThemeAssets
|
compileTask.dependsOn copyThemeAssets
|
||||||
compileTask.dependsOn copyVtmAssets
|
compileTask.dependsOn copyVtmAssets
|
||||||
compileTask.dependsOn copyWarSources
|
compileTask.dependsOn copyWarSources
|
||||||
}
|
|
||||||
|
|
||||||
// Configuring Eclipse classpath
|
|
||||||
eclipse.classpath {
|
|
||||||
|
|
||||||
defaultOutputDir = file('war/WEB-INF/classes')
|
|
||||||
|
|
||||||
//file {
|
|
||||||
// whenMerged { classpath ->
|
|
||||||
// classpath.entries.findAll { entry ->
|
|
||||||
// entry.path == 'src' }*.excludes = ['main','org/oscim/gdx/emu/']
|
|
||||||
// }
|
|
||||||
//}
|
|
||||||
}
|
}
|
||||||
|
@ -1,36 +1,35 @@
|
|||||||
buildscript {
|
buildscript {
|
||||||
repositories {
|
repositories {
|
||||||
mavenLocal()
|
mavenLocal()
|
||||||
mavenCentral()
|
mavenCentral()
|
||||||
maven { url 'http://dl.bintray.com/steffenschaefer/maven' }
|
maven { url 'http://dl.bintray.com/steffenschaefer/maven' }
|
||||||
}
|
}
|
||||||
dependencies {
|
dependencies {
|
||||||
classpath 'de.richsource.gradle.plugins:gwt-gradle-plugin:0.5'
|
classpath 'de.richsource.gradle.plugins:gwt-gradle-plugin:0.5'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
repositories {
|
repositories {
|
||||||
maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
|
maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
|
||||||
}
|
}
|
||||||
|
|
||||||
apply plugin: 'war'
|
apply plugin: 'war'
|
||||||
apply plugin: 'jetty'
|
apply plugin: 'jetty'
|
||||||
apply plugin: 'gwt'
|
apply plugin: 'gwt'
|
||||||
apply plugin: 'eclipse'
|
|
||||||
|
|
||||||
sourceSets {
|
sourceSets {
|
||||||
main.java.srcDirs = ['src']
|
main.java.srcDirs = ['src']
|
||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
providedCompile project(':vtm-web')
|
providedCompile project(':vtm-web')
|
||||||
providedCompile project(':vtm-extras')
|
providedCompile project(':vtm-extras')
|
||||||
providedCompile "com.badlogicgames.gdx:gdx:$gdxVersion:sources"
|
providedCompile "com.badlogicgames.gdx:gdx:$gdxVersion:sources"
|
||||||
providedCompile "com.badlogicgames.gdx:gdx-backend-gwt:$gdxVersion:sources"
|
providedCompile "com.badlogicgames.gdx:gdx-backend-gwt:$gdxVersion:sources"
|
||||||
providedCompile "com.badlogicgames.gdx:gdx-backend-gwt:$gdxVersion"
|
providedCompile "com.badlogicgames.gdx:gdx-backend-gwt:$gdxVersion"
|
||||||
providedCompile 'ru.finam:slf4j-gwt:1.2.1'
|
providedCompile 'ru.finam:slf4j-gwt:1.2.1'
|
||||||
providedCompile 'org.slf4j:slf4j-api:1.7.5'
|
providedCompile 'org.slf4j:slf4j-api:1.7.5'
|
||||||
providedCompile 'org.timepedia.exporter:gwtexporter:2.5.0-SNAPSHOT'
|
providedCompile 'org.timepedia.exporter:gwtexporter:2.5.0-SNAPSHOT'
|
||||||
}
|
}
|
||||||
|
|
||||||
// explicit dependencies for org.gradle.configureondemand=true
|
// explicit dependencies for org.gradle.configureondemand=true
|
||||||
@ -40,31 +39,31 @@ evaluationDependsOn(':vtm-gdx')
|
|||||||
evaluationDependsOn(':vtm-web')
|
evaluationDependsOn(':vtm-web')
|
||||||
|
|
||||||
gwt {
|
gwt {
|
||||||
gwtVersion='2.6.1'
|
gwtVersion = '2.6.1'
|
||||||
modules 'org.oscim.web.VtmWebJs'
|
modules 'org.oscim.web.VtmWebJs'
|
||||||
|
|
||||||
superDev {
|
superDev {
|
||||||
noPrecompile=true
|
noPrecompile = true
|
||||||
}
|
}
|
||||||
compiler {
|
compiler {
|
||||||
enableClosureCompiler = false; // activates -XenableClosureCompiler
|
enableClosureCompiler = false; // activates -XenableClosureCompiler
|
||||||
disableClassMetadata = true; // activates -XdisableClassMetadata
|
disableClassMetadata = true; // activates -XdisableClassMetadata
|
||||||
disableCastChecking = true; // activates -XdisableCastChecking
|
disableCastChecking = true; // activates -XdisableCastChecking
|
||||||
}
|
}
|
||||||
|
|
||||||
src += files(sourceSets.main.java.srcDirs)
|
src += files(sourceSets.main.java.srcDirs)
|
||||||
src += files(project(':vtm').sourceSets.main.allJava.srcDirs)
|
src += files(project(':vtm').sourceSets.main.allJava.srcDirs)
|
||||||
src += files(project(':vtm-themes').sourceSets.main.allJava.srcDirs)
|
src += files(project(':vtm-themes').sourceSets.main.allJava.srcDirs)
|
||||||
src += files(project(':vtm-themes').sourceSets.main.resources.srcDirs)
|
src += files(project(':vtm-themes').sourceSets.main.resources.srcDirs)
|
||||||
src += files(project(':vtm-gdx').sourceSets.main.allJava.srcDirs)
|
src += files(project(':vtm-gdx').sourceSets.main.allJava.srcDirs)
|
||||||
src += files(project(':vtm-web').sourceSets.main.allJava.srcDirs)
|
src += files(project(':vtm-web').sourceSets.main.allJava.srcDirs)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Run jetty with draft compiled war
|
// Run jetty with draft compiled war
|
||||||
task jettyDraftWar(type: JettyRunWar) {
|
task jettyDraftWar(type: JettyRunWar) {
|
||||||
dependsOn draftWar
|
dependsOn draftWar
|
||||||
//dependsOn.remove('war')
|
//dependsOn.remove('war')
|
||||||
webApp=draftWar.archivePath
|
webApp = draftWar.archivePath
|
||||||
}
|
}
|
||||||
|
|
||||||
task copyThemeAssets(type: Copy) {
|
task copyThemeAssets(type: Copy) {
|
||||||
@ -88,20 +87,7 @@ task copyWarSources(type: Copy) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
tasks.withType(JavaCompile) { compileTask ->
|
tasks.withType(JavaCompile) { compileTask ->
|
||||||
compileTask.dependsOn copyThemeAssets
|
compileTask.dependsOn copyThemeAssets
|
||||||
compileTask.dependsOn copyVtmAssets
|
compileTask.dependsOn copyVtmAssets
|
||||||
compileTask.dependsOn copyWarSources
|
compileTask.dependsOn copyWarSources
|
||||||
}
|
|
||||||
|
|
||||||
// Configuring Eclipse classpath
|
|
||||||
eclipse.classpath {
|
|
||||||
|
|
||||||
defaultOutputDir = file('war/WEB-INF/classes')
|
|
||||||
|
|
||||||
//file {
|
|
||||||
// whenMerged { classpath ->
|
|
||||||
// classpath.entries.findAll { entry ->
|
|
||||||
// entry.path == 'src' }*.excludes = ['main','org/oscim/gdx/emu/']
|
|
||||||
// }
|
|
||||||
//}
|
|
||||||
}
|
}
|
||||||
|
@ -1,36 +1,35 @@
|
|||||||
buildscript {
|
buildscript {
|
||||||
repositories {
|
repositories {
|
||||||
mavenLocal()
|
mavenLocal()
|
||||||
mavenCentral()
|
mavenCentral()
|
||||||
maven { url 'http://dl.bintray.com/steffenschaefer/maven' }
|
maven { url 'http://dl.bintray.com/steffenschaefer/maven' }
|
||||||
}
|
}
|
||||||
dependencies {
|
dependencies {
|
||||||
classpath 'de.richsource.gradle.plugins:gwt-gradle-plugin:0.5'
|
classpath 'de.richsource.gradle.plugins:gwt-gradle-plugin:0.5'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
repositories {
|
repositories {
|
||||||
maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
|
maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
|
||||||
}
|
}
|
||||||
|
|
||||||
//apply plugin: 'war'
|
//apply plugin: 'war'
|
||||||
//apply plugin: 'jetty'
|
//apply plugin: 'jetty'
|
||||||
apply plugin: 'java'
|
apply plugin: 'java'
|
||||||
apply plugin: 'gwt-base'
|
apply plugin: 'gwt-base'
|
||||||
apply plugin: 'eclipse'
|
|
||||||
|
|
||||||
sourceSets {
|
sourceSets {
|
||||||
main.java.srcDirs = ['src', 'src/org/oscim/gdx/emu']
|
main.java.srcDirs = ['src', 'src/org/oscim/gdx/emu']
|
||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
compile project(':vtm-gdx')
|
compile project(':vtm-gdx')
|
||||||
compile project(':vtm-extras')
|
compile project(':vtm-extras')
|
||||||
compile "com.badlogicgames.gdx:gdx:$gdxVersion:sources"
|
compile "com.badlogicgames.gdx:gdx:$gdxVersion:sources"
|
||||||
compile "com.badlogicgames.gdx:gdx-backend-gwt:$gdxVersion:sources"
|
compile "com.badlogicgames.gdx:gdx-backend-gwt:$gdxVersion:sources"
|
||||||
compile "com.badlogicgames.gdx:gdx-backend-gwt:$gdxVersion"
|
compile "com.badlogicgames.gdx:gdx-backend-gwt:$gdxVersion"
|
||||||
compile 'ru.finam:slf4j-gwt:1.2.1'
|
compile 'ru.finam:slf4j-gwt:1.2.1'
|
||||||
compile 'org.slf4j:slf4j-api:1.7.5'
|
compile 'org.slf4j:slf4j-api:1.7.5'
|
||||||
}
|
}
|
||||||
|
|
||||||
// explicit dependencies for org.gradle.configureondemand=true
|
// explicit dependencies for org.gradle.configureondemand=true
|
||||||
@ -40,23 +39,23 @@ evaluationDependsOn(':vtm-gdx')
|
|||||||
evaluationDependsOn(':vtm-extras')
|
evaluationDependsOn(':vtm-extras')
|
||||||
|
|
||||||
gwt {
|
gwt {
|
||||||
gwtVersion='2.6.1'
|
gwtVersion = '2.6.1'
|
||||||
modules 'org.oscim.gdx.VtmWeb'
|
modules 'org.oscim.gdx.VtmWeb'
|
||||||
|
|
||||||
superDev {
|
superDev {
|
||||||
noPrecompile=true
|
noPrecompile = true
|
||||||
}
|
}
|
||||||
compiler {
|
compiler {
|
||||||
enableClosureCompiler = false; // activates -XenableClosureCompiler
|
enableClosureCompiler = false; // activates -XenableClosureCompiler
|
||||||
disableClassMetadata = true; // activates -XdisableClassMetadata
|
disableClassMetadata = true; // activates -XdisableClassMetadata
|
||||||
disableCastChecking = true; // activates -XdisableCastChecking
|
disableCastChecking = true; // activates -XdisableCastChecking
|
||||||
}
|
}
|
||||||
|
|
||||||
src += files(sourceSets.main.java.srcDirs)
|
src += files(sourceSets.main.java.srcDirs)
|
||||||
src += files(project(':vtm').sourceSets.main.allJava.srcDirs)
|
src += files(project(':vtm').sourceSets.main.allJava.srcDirs)
|
||||||
src += files(project(':vtm-themes').sourceSets.main.allJava.srcDirs)
|
src += files(project(':vtm-themes').sourceSets.main.allJava.srcDirs)
|
||||||
src += files(project(':vtm-themes').sourceSets.main.resources.srcDirs)
|
src += files(project(':vtm-themes').sourceSets.main.resources.srcDirs)
|
||||||
src += files(project(':vtm-gdx').sourceSets.main.allJava.srcDirs)
|
src += files(project(':vtm-gdx').sourceSets.main.allJava.srcDirs)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Run jetty with draft compiled war
|
// Run jetty with draft compiled war
|
||||||
@ -82,16 +81,3 @@ gwt {
|
|||||||
// compileTask.dependsOn copyThemeAssets
|
// compileTask.dependsOn copyThemeAssets
|
||||||
// compileTask.dependsOn copyVtmAssets
|
// compileTask.dependsOn copyVtmAssets
|
||||||
//}
|
//}
|
||||||
|
|
||||||
// Configuring Eclipse classpath
|
|
||||||
eclipse.classpath {
|
|
||||||
|
|
||||||
defaultOutputDir = file('war/WEB-INF/classes')
|
|
||||||
|
|
||||||
file {
|
|
||||||
whenMerged { classpath ->
|
|
||||||
classpath.entries.findAll { entry ->
|
|
||||||
entry.path == 'src' }*.excludes = ['main','org/oscim/gdx/emu/']
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
@ -4,35 +4,14 @@ apply plugin: 'maven'
|
|||||||
configurations { providedCompile }
|
configurations { providedCompile }
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
compile 'org.slf4j:slf4j-api:1.7.6'
|
compile 'com.vividsolutions:jts:1.13'
|
||||||
compile 'com.vividsolutions:jts:1.13'
|
compile 'org.slf4j:slf4j-api:1.7.21'
|
||||||
providedCompile 'com.squareup.okhttp:okhttp:1.5.2'
|
providedCompile 'com.google.code.findbugs:annotations:2.0.1'
|
||||||
providedCompile 'com.google.code.findbugs:annotations:2.0.1'
|
providedCompile 'com.squareup.okhttp:okhttp:1.5.2'
|
||||||
}
|
}
|
||||||
|
|
||||||
sourceSets {
|
sourceSets {
|
||||||
main.java.srcDirs = ['src']
|
main.java.srcDirs = ['src']
|
||||||
main.resources.srcDirs = ['resources']
|
main.resources.srcDirs = ['resources']
|
||||||
main.compileClasspath += configurations.providedCompile
|
main.compileClasspath += configurations.providedCompile
|
||||||
}
|
|
||||||
|
|
||||||
eclipse.classpath {
|
|
||||||
//you can tweak the classpath of the Eclipse project by adding extra configurations:
|
|
||||||
plusConfigurations += [ configurations.providedCompile ]
|
|
||||||
|
|
||||||
file.whenMerged { classpath ->
|
|
||||||
classpath.entries.findAll { entry ->
|
|
||||||
entry.path.contains('annotations') ||
|
|
||||||
entry.path.contains('okhttp') ||
|
|
||||||
entry.path.contains('okio')
|
|
||||||
}*.exported = false
|
|
||||||
}
|
|
||||||
|
|
||||||
//if you don't want some classpath entries 'exported' in Eclipse
|
|
||||||
noExportConfigurations += [ configurations.providedCompile ]
|
|
||||||
|
|
||||||
|
|
||||||
//default settings for downloading sources and Javadoc:
|
|
||||||
//downloadSources = true
|
|
||||||
//downloadJavadoc = false
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user