2017-03-27 04:01:10 -07:00
|
|
|
// Top-level build file where you can add configuration options common to all sub-projects/modules.
|
|
|
|
buildscript {
|
|
|
|
repositories {
|
|
|
|
jcenter()
|
|
|
|
}
|
|
|
|
dependencies {
|
|
|
|
classpath 'com.android.tools.build:gradle:2.3.0'
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-01-10 04:11:55 -08:00
|
|
|
final File repoDir = project.file('libs')
|
2017-03-27 04:01:10 -07:00
|
|
|
allprojects {
|
|
|
|
repositories {
|
|
|
|
jcenter()
|
|
|
|
}
|
2018-01-10 04:11:55 -08:00
|
|
|
repositories {
|
|
|
|
//bitcoin-json-rpc-client-1.0.jar isn't part of any well known maven repo
|
|
|
|
//so we search the libs dir; gradle generates (guesses) metadata except dependencies.
|
|
|
|
//Artifacts from repos with real metadata take precedence.
|
|
|
|
flatDir {
|
|
|
|
dirs repoDir
|
|
|
|
}
|
|
|
|
}
|
2018-03-08 07:08:05 -08:00
|
|
|
//cross-compilation stuff for Java 7
|
|
|
|
assert (System.env.JDK_7_HOME != null): "Set environment property JDK_7_HOME"
|
|
|
|
project.ext.targetJavaHome = System.env.JDK_7_HOME
|
|
|
|
def javaExecutablesPath = new File(targetJavaHome, 'bin')
|
|
|
|
def javaExecutables = [:].withDefault { execName ->
|
|
|
|
def executable = new File(javaExecutablesPath, execName)
|
|
|
|
assert executable.exists(): "There is no ${execName} executable in ${javaExecutablesPath}"
|
|
|
|
executable
|
|
|
|
}
|
|
|
|
tasks.withType(JavaCompile) {
|
2018-03-08 09:35:43 -08:00
|
|
|
project.sourceCompatibility = '1.7'
|
2018-03-08 07:08:05 -08:00
|
|
|
options.with {
|
|
|
|
fork = true
|
|
|
|
forkOptions.javaHome = file(targetJavaHome)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
tasks.withType(Javadoc) {
|
|
|
|
executable = javaExecutables.javadoc
|
|
|
|
}
|
|
|
|
tasks.withType(Test) {
|
|
|
|
executable = javaExecutables.java
|
|
|
|
}
|
|
|
|
tasks.withType(JavaExec) {
|
|
|
|
executable = javaExecutables.java
|
|
|
|
}
|
2017-03-27 04:01:10 -07:00
|
|
|
}
|
2018-01-22 09:12:22 -08:00
|
|
|
|
|
|
|
ext.with {
|
|
|
|
BatmDependencySubstitutionConfig = file('dependencySubstitutions.txt')
|
|
|
|
}
|