Skip to content

Commit

Permalink
Updating Master build files to fix build
Browse files Browse the repository at this point in the history
Signed-off-by: James Sutton <[email protected]>
  • Loading branch information
jpwsutton committed Nov 7, 2016
1 parent b43eafa commit 21d0b70
Show file tree
Hide file tree
Showing 5 changed files with 32 additions and 13 deletions.
34 changes: 26 additions & 8 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,9 @@ buildscript {
repositories {
jcenter()
mavenCentral()
maven { url "https://jitpack.io" }
}
dependencies {
//classpath 'com.android.tools.build:gradle:2.0.0'
classpath 'com.android.tools.build:gradle:2.0.0'
//classpath 'com.jakewharton.sdkmanager:gradle-plugin:0.12.+'
// Work around to fix build
//classpath 'com.github.JakeWharton:sdk-manager-plugin:1d29782dd6'
classpath 'com.github.sschuberth:sdk-manager-plugin:master-SNAPSHOT'
classpath 'com.android.tools.build:gradle:2.2.1'
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
Expand All @@ -33,16 +27,40 @@ ext{

clientVersion = '1.1.0'

mavenUrl = "https://repo.eclipse.org/content/repositories/paho-snapshots/"
mavenUrl = "https://repo.eclipse.org/content/repositories/paho-releases/"

supportLibVersion = '23.3.0'

}

def getSdkDirFromLocalProperties() {
def rootDir = project.rootDir
def localProperties = new File(rootDir, "local.properties")
Properties properties = new Properties()
localProperties.withInputStream { instr ->
properties.load(instr)
}
properties.getProperty('sdk.dir')
}

def androidHome = System.env['ANDROID_HOME']

def androidHomeIsDefined = androidHome?.trim()

def sdkDir = androidHomeIsDefined ? androidHome : getSdkDirFromLocalProperties()

println "SDK dir: $sdkDir"


allprojects {

repositories {
jcenter()
maven {
url "file://$sdkDir/extras/android/m2repository/"
}
}

version = rootProject.ext.serviceVersion
group = rootProject.ext.group
}
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-2.12-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-2.14.1-all.zip
3 changes: 1 addition & 2 deletions org.eclipse.paho.android.sample/build.gradle
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
apply plugin: 'android-sdk-manager'
apply plugin: 'com.android.application'

android {
Expand Down Expand Up @@ -52,4 +51,4 @@ task publishAPK(type: Copy) {
configurations.compile.exclude module: 'org.eclipse.paho.client.mqttv3'
task debug << {
configurations.compile.each { println it}
}
}
1 change: 0 additions & 1 deletion org.eclipse.paho.android.service/build.gradle
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
apply plugin: 'android-sdk-manager'
apply plugin: 'com.android.library'
apply plugin: 'maven-publish'

Expand Down
5 changes: 4 additions & 1 deletion paho.mqtt.android.example/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ android {
dexOptions {
preDexLibraries = false
}
lintOptions {
abortOnError false
}
}

repositories {
Expand All @@ -43,4 +46,4 @@ dependencies {
configurations.compile.exclude module: 'org.eclipse.paho.client.mqttv3'
task debug << {
configurations.compile.each { println it}
}
}

0 comments on commit 21d0b70

Please sign in to comment.