gradle: update to 2.1 and android targetSdk 21
- add android-appcompat subproject
This commit is contained in:
parent
0bc45dfd74
commit
f4ffac44d2
3
.gitmodules
vendored
3
.gitmodules
vendored
@ -6,3 +6,6 @@
|
||||
path = jni/jni/libtess2
|
||||
url = https://github.com/memononen/libtess2.git
|
||||
|
||||
[submodule "appcompat"]
|
||||
path = appcompat
|
||||
url = https://github.com/hjanetzek/android-support-v7-appcompat.git
|
||||
|
||||
51
.travis.yml
51
.travis.yml
@ -1,34 +1,63 @@
|
||||
# from https://github.com/Ruenzuo/android-cd-travis-example/blob/master/.travis.yml
|
||||
|
||||
language: java
|
||||
jdk: openjdk7
|
||||
jdk:
|
||||
- openjdk7
|
||||
|
||||
env:
|
||||
matrix:
|
||||
- ANDROID_SDKS=android-19 ANDROID_TARGET=android-19 ANDROID_ABI=armeabi-v7a
|
||||
#branches:
|
||||
# only:
|
||||
# - master
|
||||
- ANDROID_SDKS=android-21 ANDROID_TARGET=android-21 ANDROID_ABI=armeabi-v7a
|
||||
|
||||
branches:
|
||||
only:
|
||||
- master
|
||||
|
||||
before_install:
|
||||
- chmod +x gradlew
|
||||
# Install base Android SDK
|
||||
- sudo apt-get update
|
||||
- if [ `uname -m` = x86_64 ]; then sudo apt-get install --force-yes libgd2-xpm ia32-libs ia32-libs-multiarch > /dev/null; fi
|
||||
- wget http://dl.google.com/android/android-sdk_r23-linux.tgz
|
||||
- tar xzf android-sdk_r23-linux.tgz
|
||||
- wget http://dl.google.com/android/android-sdk_r23.0.2-linux.tgz
|
||||
- tar xzf android-sdk_r23.0.2-linux.tgz
|
||||
- export ANDROID_HOME=$PWD/android-sdk-linux
|
||||
- export PATH=${PATH}:${ANDROID_HOME}/tools:${ANDROID_HOME}/platform-tools
|
||||
# install android build tools
|
||||
- wget https://dl-ssl.google.com/android/repository/build-tools_r20-linux.zip
|
||||
- unzip build-tools_r20-linux.zip -d $ANDROID_HOME
|
||||
- wget https://dl-ssl.google.com/android/repository/build-tools_r21.0.2-linux.zip
|
||||
- unzip build-tools_r21.0.2-linux.zip -d $ANDROID_HOME
|
||||
- mkdir -p $ANDROID_HOME/build-tools/
|
||||
- mv $ANDROID_HOME/android-4.4W $ANDROID_HOME/build-tools/20.0.0
|
||||
- mv $ANDROID_HOME/android-5.0 $ANDROID_HOME/build-tools/21.0.2
|
||||
# Install required components.
|
||||
# For a full list, run `android list sdk -a --extended`
|
||||
# Note that sysimg-18 downloads the ARM, x86 and MIPS images (we should optimize this).
|
||||
# Other relevant API's
|
||||
- echo yes | android update sdk --filter platform-tools --no-ui --force
|
||||
- echo yes | android update sdk --filter android-19 --no-ui --force
|
||||
- echo yes | android update sdk --filter android-21 --no-ui --force
|
||||
- echo yes | android update sdk --filter extra-android-support --no-ui --force
|
||||
- echo yes | android update sdk --filter extra-android-m2repository --no-ui --force
|
||||
# Create and start emulator
|
||||
#- echo no | android create avd --force -n test -t $ANDROID_TARGET --abi $ANDROID_ABI
|
||||
#- emulator -avd test -no-skin -no-audio -no-window &
|
||||
|
||||
|
||||
# language: android
|
||||
# android:
|
||||
# components:
|
||||
# # Uncomment the lines below if you want to
|
||||
# # use the latest revision of Android SDK Tools
|
||||
# - platform-tools
|
||||
# - tools
|
||||
# # The BuildTools version used by your project
|
||||
# # - build-tools-21.0.1
|
||||
# # The SDK version used to compile your project
|
||||
# - android-21
|
||||
# # Additional components
|
||||
# - extra-android-support
|
||||
# # - extra-google-google_play_services
|
||||
# - extra-google-m2repository
|
||||
# - extra-android-m2repository
|
||||
# - addon-google_apis-google-21
|
||||
# # Specify at least one system image,
|
||||
# # if you need to run emulator(s) during your tests
|
||||
# #- sys-img-armeabi-v7a-android-19
|
||||
# #- sys-img-x86-android-17
|
||||
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
#!/bin/bash
|
||||
export PATH=$PATH:$ANDROID_HOME/platform-tools:$ANDROID_HOME/tools
|
||||
echo yes | android update sdk --filter platform-tools --no-ui
|
||||
echo yes | android update sdk --filter android-19 --no-ui
|
||||
echo yes | android update sdk --filter android-21 --no-ui
|
||||
echo yes | android update sdk --filter extra-android-support --no-ui
|
||||
echo yes | android update sdk --filter extra-android-m2repository --no-ui
|
||||
|
||||
1
appcompat
Submodule
1
appcompat
Submodule
@ -0,0 +1 @@
|
||||
Subproject commit eead2062deaeda844de58777247f517427459e0d
|
||||
36
build.gradle
36
build.gradle
@ -6,32 +6,51 @@ buildscript {
|
||||
|
||||
dependencies {
|
||||
classpath 'org.gradle.api.plugins:gradle-nexus-plugin:0.3'
|
||||
|
||||
classpath 'com.android.tools.build:gradle:0.13.1'
|
||||
|
||||
// for aar/maven stuff
|
||||
// https://github.com/dcendents/android-maven-plugin
|
||||
classpath 'com.github.dcendents:android-maven-plugin:1.1'
|
||||
}
|
||||
}
|
||||
|
||||
task wrapper(type: Wrapper) {
|
||||
gradleVersion = '1.12'
|
||||
def filterProjects(filter) {
|
||||
return subprojects.findAll { project -> filter.contains(project.name) }
|
||||
}
|
||||
|
||||
apply from:'jdee.gradle'
|
||||
task wrapper(type: Wrapper) {
|
||||
gradleVersion = '2.1'
|
||||
}
|
||||
|
||||
//apply from:'jdee.gradle'
|
||||
|
||||
allprojects {
|
||||
group = 'org.oscim'
|
||||
version = '0.5.9-SNAPSHOT'
|
||||
version = '0.6.0-SNAPSHOT'
|
||||
|
||||
ext.gdxVersion = "1.2.0"
|
||||
ext.gdxVersion = "1.4.1"
|
||||
ext.androidBuildVersionTools = "21.0.2"
|
||||
|
||||
repositories {
|
||||
mavenCentral()
|
||||
// Jeo
|
||||
maven { url 'http://repo.boundlessgeo.com/main' }
|
||||
//maven { url 'https://github.com/hjanetzek/maven-repo/raw/master/' }
|
||||
mavenLocal()
|
||||
// Local andoird repo
|
||||
maven { url "${System.env.ANDROID_HOME}/extras/android/m2repository" }
|
||||
}
|
||||
|
||||
// create IntelliJ project settings - untested
|
||||
apply plugin: 'idea'
|
||||
}
|
||||
|
||||
def androidMinSdk() { return 10 }
|
||||
def androidTargetSdk() { return 21 }
|
||||
def versionCode() { return 50 }
|
||||
def versionName() { return version }
|
||||
|
||||
subprojects {
|
||||
// create eclipse project settings
|
||||
apply plugin: 'eclipse'
|
||||
@ -43,14 +62,13 @@ subprojects {
|
||||
}
|
||||
|
||||
tasks.withType(JavaCompile) {
|
||||
sourceCompatibility = "1.7"
|
||||
targetCompatibility = "1.7"
|
||||
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'
|
||||
//apply from:'../jdee.gradle'
|
||||
}
|
||||
|
||||
|
||||
@ -18,4 +18,5 @@ org.gradle.jvmargs=-Xmx1024m -XX:MaxPermSize=512m
|
||||
|
||||
# options to speed up compilation once everything else is working:
|
||||
org.gradle.parallel=false
|
||||
org.gradle.configureondemand=true
|
||||
org.gradle.configureondemand=false
|
||||
|
||||
|
||||
BIN
gradle/wrapper/gradle-wrapper.jar
vendored
BIN
gradle/wrapper/gradle-wrapper.jar
vendored
Binary file not shown.
4
gradle/wrapper/gradle-wrapper.properties
vendored
4
gradle/wrapper/gradle-wrapper.properties
vendored
@ -1,6 +1,6 @@
|
||||
#Mon Jun 09 05:36:37 CEST 2014
|
||||
#Sun Oct 19 16:09:27 CEST 2014
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
zipStorePath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-1.12-bin.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-2.1-bin.zip
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
include ':appcompat'
|
||||
include ':vtm'
|
||||
include ':vtm-tests'
|
||||
include ':vtm-extras'
|
||||
|
||||
@ -10,13 +10,13 @@
|
||||
|
||||
<uses-sdk
|
||||
android:minSdkVersion="10"
|
||||
android:targetSdkVersion="19" />
|
||||
android:targetSdkVersion="21" />
|
||||
|
||||
<application
|
||||
android:allowBackup="true"
|
||||
android:icon="@drawable/ic_launcher"
|
||||
android:label="@string/app_name" >
|
||||
<!-- android:theme="@android:style/Theme.NoTitleBar.Fullscreen" -->
|
||||
android:label="@string/app_name">
|
||||
<!-- android:theme="@style/AppTheme" -->
|
||||
<activity
|
||||
android:name="org.oscim.android.test.Samples"
|
||||
android:label="@string/app_name" >
|
||||
|
||||
@ -1,28 +1,22 @@
|
||||
buildscript {
|
||||
repositories {
|
||||
mavenCentral()
|
||||
}
|
||||
dependencies {
|
||||
classpath 'com.android.tools.build:gradle:0.12.+'
|
||||
}
|
||||
}
|
||||
apply plugin: 'com.android.application'
|
||||
|
||||
repositories {
|
||||
maven { url "${System.env.ANDROID_HOME}/extras/android/m2repository" }
|
||||
}
|
||||
|
||||
apply plugin: 'android'
|
||||
configurations { providedCompile }
|
||||
|
||||
dependencies {
|
||||
compile project(':vtm-android')
|
||||
compile project(':vtm-jeo')
|
||||
compile project(':vtm-extras')
|
||||
compile project(':vtm-themes')
|
||||
|
||||
compile project(':appcompat')
|
||||
//compile 'com.android.support:support-v4:21.+'
|
||||
|
||||
compile 'com.noveogroup.android:android-logger:1.3.4'
|
||||
}
|
||||
|
||||
android {
|
||||
compileSdkVersion 19
|
||||
buildToolsVersion '20.0'
|
||||
compileSdkVersion androidTargetSdk()
|
||||
buildToolsVersion "$androidBuildVersionTools"
|
||||
|
||||
sourceSets {
|
||||
main {
|
||||
@ -33,6 +27,11 @@ android {
|
||||
assets.srcDirs = ['assets']
|
||||
}
|
||||
|
||||
compileOptions {
|
||||
sourceCompatibility JavaVersion.VERSION_1_7
|
||||
targetCompatibility JavaVersion.VERSION_1_7
|
||||
}
|
||||
|
||||
debug.setRoot('build-types/debug')
|
||||
release.setRoot('build-types/release')
|
||||
}
|
||||
@ -47,16 +46,35 @@ android {
|
||||
lintOptions.abortOnError false
|
||||
}
|
||||
|
||||
// Including configurations into Eclipse
|
||||
|
||||
|
||||
// Configuring Eclipse classpath
|
||||
eclipse.classpath {
|
||||
plusConfigurations += configurations.compile
|
||||
eclipse {
|
||||
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 {
|
||||
// Manipulation of the classpath XML before merging local
|
||||
// and generated copies
|
||||
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')
|
||||
}*.exported = false
|
||||
}
|
||||
|
||||
// Direct manipulation of the generated classpath XML
|
||||
withXml {
|
||||
def node = it.asNode()
|
||||
@ -64,18 +82,16 @@ eclipse.classpath {
|
||||
node.appendNode('classpathentry kind="src" path="gen"')
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
eclipse.project {
|
||||
}
|
||||
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'
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
task run (dependsOn: 'installDebug'){
|
||||
doFirst {
|
||||
println(">> adb run...")
|
||||
|
||||
@ -11,5 +11,6 @@
|
||||
#proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt
|
||||
|
||||
# Project target.
|
||||
target=android-19
|
||||
target=android-21
|
||||
android.library.reference.1=../vtm-android
|
||||
android.library.reference.2=../appcompat
|
||||
|
||||
@ -1,24 +1,11 @@
|
||||
buildscript {
|
||||
repositories {
|
||||
mavenCentral()
|
||||
}
|
||||
dependencies {
|
||||
classpath 'com.android.tools.build:gradle:0.12.+'
|
||||
}
|
||||
}
|
||||
|
||||
repositories {
|
||||
maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
|
||||
}
|
||||
|
||||
apply plugin: 'android'
|
||||
apply plugin: 'com.android.application'
|
||||
|
||||
configurations { providedCompile }
|
||||
|
||||
dependencies {
|
||||
compile project(':vtm-gdx')
|
||||
compile project(':vtm-themes')
|
||||
compile 'com.noveogroup.android:android-logger:1.3.1'
|
||||
compile 'com.noveogroup.android:android-logger:1.3.4'
|
||||
compile "com.badlogicgames.gdx:gdx-backend-android:$gdxVersion"
|
||||
//compile "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-armeabi"
|
||||
//compile "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-armeabi-v7a"
|
||||
@ -36,8 +23,8 @@ dependencies {
|
||||
// compileTask.dependsOn copyLibs }
|
||||
|
||||
android {
|
||||
compileSdkVersion 19
|
||||
buildToolsVersion '20.0'
|
||||
compileSdkVersion androidTargetSdk()
|
||||
buildToolsVersion "$androidBuildVersionTools"
|
||||
|
||||
sourceSets {
|
||||
main {
|
||||
@ -50,6 +37,11 @@ android {
|
||||
assets.srcDirs = ['assets']
|
||||
}
|
||||
|
||||
compileOptions {
|
||||
sourceCompatibility JavaVersion.VERSION_1_7
|
||||
targetCompatibility JavaVersion.VERSION_1_7
|
||||
}
|
||||
|
||||
debug.setRoot('build-types/debug')
|
||||
release.setRoot('build-types/release')
|
||||
}
|
||||
@ -57,28 +49,37 @@ android {
|
||||
|
||||
// Including configurations into Eclipse
|
||||
eclipse {
|
||||
jdt {
|
||||
sourceCompatibility = 1.6
|
||||
targetCompatibility = 1.6
|
||||
}
|
||||
|
||||
// Configuring Eclipse classpath
|
||||
classpath {
|
||||
plusConfigurations += configurations.compile
|
||||
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('native-libs') }*.exported = false
|
||||
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()
|
||||
|
||||
@ -8,4 +8,4 @@
|
||||
# project structure.
|
||||
|
||||
# Project target.
|
||||
target=android-19
|
||||
target=android-21
|
||||
|
||||
@ -9,13 +9,13 @@
|
||||
|
||||
<uses-sdk
|
||||
android:minSdkVersion="10"
|
||||
android:targetSdkVersion="19" />
|
||||
android:targetSdkVersion="21" />
|
||||
|
||||
<application
|
||||
android:label="VTM Start"
|
||||
android:icon="@drawable/ic_launcher"
|
||||
android:allowBackup="true"
|
||||
android:theme="@android:style/Theme.NoTitleBar.Fullscreen" >
|
||||
android:allowBackup="true" >
|
||||
<!-- android:theme="@style/AppTheme" -->
|
||||
<activity
|
||||
android:name="org.oscim.android.start.TestActivity"
|
||||
android:label="VTM Start" >
|
||||
|
||||
@ -1,26 +1,21 @@
|
||||
buildscript {
|
||||
repositories {
|
||||
mavenCentral()
|
||||
}
|
||||
dependencies {
|
||||
classpath 'com.android.tools.build:gradle:0.12.+'
|
||||
}
|
||||
}
|
||||
apply plugin: 'com.android.application'
|
||||
|
||||
repositories {
|
||||
maven { url "${System.env.ANDROID_HOME}/extras/android/m2repository" }
|
||||
}
|
||||
|
||||
apply plugin: 'android'
|
||||
configurations { providedCompile }
|
||||
|
||||
dependencies {
|
||||
compile project(':vtm-android')
|
||||
compile project(':vtm-themes')
|
||||
|
||||
compile project(':appcompat')
|
||||
//compile 'com.android.support:support-v4:21.+'
|
||||
//compile 'com.android.support:appcompat-v7:21.0.0'
|
||||
|
||||
compile 'com.noveogroup.android:android-logger:1.3.4'
|
||||
}
|
||||
|
||||
android {
|
||||
compileSdkVersion 19
|
||||
buildToolsVersion '20.0'
|
||||
compileSdkVersion androidTargetSdk()
|
||||
buildToolsVersion "$androidBuildVersionTools"
|
||||
|
||||
sourceSets {
|
||||
main {
|
||||
@ -31,6 +26,11 @@ android {
|
||||
assets.srcDirs = ['assets']
|
||||
}
|
||||
|
||||
compileOptions {
|
||||
sourceCompatibility JavaVersion.VERSION_1_7
|
||||
targetCompatibility JavaVersion.VERSION_1_7
|
||||
}
|
||||
|
||||
debug.setRoot('build-types/debug')
|
||||
release.setRoot('build-types/release')
|
||||
}
|
||||
@ -39,16 +39,38 @@ android {
|
||||
lintOptions.abortOnError false
|
||||
}
|
||||
|
||||
// Including configurations into Eclipse
|
||||
//Including configurations into Eclipse
|
||||
eclipse {
|
||||
|
||||
// Configuring Eclipse classpath
|
||||
classpath {
|
||||
plusConfigurations += configurations.compile
|
||||
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 {
|
||||
// Manipulation of the classpath XML before merging local
|
||||
// and generated copies
|
||||
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')
|
||||
}*.exported = false
|
||||
}
|
||||
|
||||
// Direct manipulation of the generated classpath XML
|
||||
withXml {
|
||||
def node = it.asNode()
|
||||
@ -61,7 +83,6 @@ eclipse {
|
||||
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'
|
||||
@ -70,9 +91,9 @@ eclipse {
|
||||
|
||||
task run (dependsOn: 'installDebug'){
|
||||
doFirst {
|
||||
println(">> adb run...")
|
||||
println(">> adb run <<")
|
||||
String adb = System.getenv()['ANDROID_HOME'] + '/platform-tools/adb'
|
||||
String cmd = "${adb} shell am start -n org.oscim.jeo.android/.TestActivity"
|
||||
String cmd = "${adb} shell am start -n org.oscim.android.start/.TestActivity"
|
||||
def proc = cmd.execute()
|
||||
proc.in.eachLine {line -> println line}
|
||||
proc.err.eachLine {line -> System.err.println( 'ERROR: ' + line)}
|
||||
|
||||
@ -11,5 +11,6 @@
|
||||
#proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt
|
||||
|
||||
# Project target.
|
||||
target=android-19
|
||||
android.library.reference.1=../vtm-android
|
||||
target=android-21
|
||||
android.library.reference.1=../appcompat
|
||||
android.library.reference.2=../vtm-android
|
||||
|
||||
@ -4,6 +4,6 @@
|
||||
|
||||
<uses-sdk
|
||||
android:minSdkVersion="10"
|
||||
android:targetSdkVersion="19" />
|
||||
android:targetSdkVersion="21" />
|
||||
|
||||
</manifest>
|
||||
@ -1,41 +1,17 @@
|
||||
buildscript {
|
||||
repositories {
|
||||
mavenCentral()
|
||||
}
|
||||
dependencies {
|
||||
classpath 'com.android.tools.build:gradle:0.12.+'
|
||||
// for aar/maven stuff
|
||||
// https://github.com/dcendents/android-maven-plugin
|
||||
classpath 'com.github.dcendents:android-maven-plugin:1.0'
|
||||
}
|
||||
}
|
||||
|
||||
apply plugin: 'android-library'
|
||||
apply plugin: 'com.android.library'
|
||||
apply plugin: 'android-maven'
|
||||
|
||||
repositories {
|
||||
maven { url "${System.env.ANDROID_HOME}/extras/android/m2repository" }
|
||||
}
|
||||
|
||||
dependencies {
|
||||
//compile 'org.oscim:vtm:0.5.9-SNAPSHOT'
|
||||
compile project(':vtm')
|
||||
provided files("${rootDir}/vtm-ext-libs/native-libs.jar")
|
||||
|
||||
compile 'com.android.support:support-v4:19.+'
|
||||
|
||||
// -> might be more efficient, but configuring
|
||||
// log-levels is way too complicated...
|
||||
// compile 'org.slf4j:slf4j-android:1.7.6'
|
||||
|
||||
compile 'com.noveogroup.android:android-logger:1.3.1'
|
||||
|
||||
// local jars will be packaged into the aar
|
||||
compile files("${rootDir}/vtm-ext-libs/native-libs.jar")
|
||||
//compile 'com.android.support:support-v4:21.+'
|
||||
compile project(':appcompat')
|
||||
}
|
||||
|
||||
android {
|
||||
compileSdkVersion 19
|
||||
buildToolsVersion '20.0'
|
||||
compileSdkVersion androidTargetSdk()
|
||||
buildToolsVersion = "$androidBuildVersionTools"
|
||||
|
||||
sourceSets {
|
||||
main {
|
||||
@ -54,25 +30,31 @@ android {
|
||||
|
||||
eclipse {
|
||||
classpath {
|
||||
plusConfigurations += configurations.compile
|
||||
plusConfigurations += [ configurations.compile, configurations.provided ]
|
||||
//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() { c ->
|
||||
c.kind == 'src'
|
||||
}
|
||||
classpath.entries.removeAll() { c -> c.kind == 'src' }
|
||||
}
|
||||
|
||||
// only used to explode jni .so into aar
|
||||
whenMerged { classpath ->
|
||||
whenMerged {
|
||||
classpath ->
|
||||
classpath.entries.findAll { entry ->
|
||||
entry.path.contains('native-libs') }*.exported = false
|
||||
entry.path.contains('native-libs') ||
|
||||
entry.path.contains('ANDROID_FRAMEWORK')
|
||||
}*.exported = false
|
||||
}
|
||||
|
||||
// Direct manipulation of the generated classpath XML
|
||||
@ -83,7 +65,6 @@ eclipse {
|
||||
// Main source directory and generated code directory
|
||||
node.appendNode('classpathentry kind="src" path="src"')
|
||||
node.appendNode('classpathentry kind="src" path="gen"')
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -10,8 +10,8 @@
|
||||
# Indicates whether an apk should be generated for each density.
|
||||
split.density=false
|
||||
# Project target.
|
||||
target=android-19
|
||||
target=android-21
|
||||
|
||||
#proguard.config=proguard.cfg
|
||||
android.library=true
|
||||
android.library.reference.1=../android-v7-appcompat
|
||||
android.library.reference.1=../appcompat
|
||||
|
||||
@ -50,6 +50,7 @@ public class Compass {
|
||||
private final SensorManager mSensorManager;
|
||||
private final Sensor mSensor;
|
||||
|
||||
@SuppressWarnings("deprecation")
|
||||
public Compass(Context context, Map map) {
|
||||
mMap = map;
|
||||
mSensorManager = (SensorManager) context
|
||||
|
||||
@ -26,8 +26,8 @@ import org.oscim.map.Map;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.content.Context;
|
||||
import android.os.Build;
|
||||
import android.util.AttributeSet;
|
||||
import android.util.DisplayMetrics;
|
||||
import android.view.GestureDetector;
|
||||
@ -89,6 +89,7 @@ public class MapView extends RelativeLayout {
|
||||
mMap.pause(false);
|
||||
}
|
||||
|
||||
@SuppressLint("ClickableViewAccessibility")
|
||||
@Override
|
||||
public boolean onTouchEvent(android.view.MotionEvent motionEvent) {
|
||||
|
||||
|
||||
@ -20,9 +20,11 @@ mainClassName = 'org.oscim.gdx.GdxMapApp'
|
||||
//}
|
||||
|
||||
sourceSets {
|
||||
main.java.srcDirs = ['src']
|
||||
main {
|
||||
java.srcDirs = ['src']
|
||||
//main.resources.srcDirs = ["${buildDir}/assets"]
|
||||
output.resourcesDir = 'assets'
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
@ -31,7 +33,7 @@ dependencies {
|
||||
//compile "com.badlogicgames.gdx:gdx-backend-lwjgl:$gdxVersion"
|
||||
compile "com.badlogicgames.gdx:gdx-backend-jglfw:$gdxVersion"
|
||||
compile "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-desktop"
|
||||
compile 'org.slf4j:slf4j-simple:1.7.5'
|
||||
compile 'org.slf4j:slf4j-simple:1.7.6'
|
||||
compile files('../vtm-ext-libs/gdx/vtm-jni-natives.jar')
|
||||
}
|
||||
|
||||
|
||||
@ -19,9 +19,11 @@ tasks.withType(JavaCompile) { compileTask ->
|
||||
}
|
||||
|
||||
sourceSets {
|
||||
main.java.srcDirs = ['src']
|
||||
main.resources.srcDirs = ["${buildDir}/assets"]
|
||||
main {
|
||||
java.srcDirs = ['src']
|
||||
resources.srcDirs = ["${buildDir}/assets"]
|
||||
output.resourcesDir = 'assets'
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
|
||||
@ -333,4 +333,10 @@ public class GwtGraphics implements Graphics {
|
||||
public GL30 getGL30() {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public long getFrameId() {
|
||||
// TODO Auto-generated method stub
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
@ -944,4 +944,16 @@ public class GwtInput implements Input {
|
||||
private static final int KEY_BACKSLASH = 220;
|
||||
private static final int KEY_CLOSE_BRACKET = 221;
|
||||
private static final int KEY_SINGLE_QUOTE = 222;
|
||||
|
||||
@Override
|
||||
public boolean isKeyJustPressed(int key) {
|
||||
// TODO Auto-generated method stub
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isCatchBackKey() {
|
||||
// TODO Auto-generated method stub
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
@ -15,12 +15,20 @@ sourceSets {
|
||||
main.compileClasspath += configurations.providedCompile
|
||||
}
|
||||
|
||||
//... there is probably a better way
|
||||
eclipse.classpath {
|
||||
plusConfigurations += configurations.providedCompile
|
||||
//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') }*.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