apply plugin: 'com.android.library'


android {
    compileSdkVersion 24
    buildToolsVersion "24.0.3"



    defaultConfig {
        minSdkVersion 21
        targetSdkVersion 24
        multiDexEnabled true
        android {
            packagingOptions {
                exclude 'META-INF/LICENSE.txt'
                exclude 'META-INF/NOTICE.txt'
                exclude 'META-INF/LICENSE'
                exclude 'META-INF/NOTICE'
                exclude 'META-INF/DEPENDENCIES'
            }
            lintOptions {
                disable 'InvalidPackage'
                abortOnError false
            }

        }

    }

    dexOptions {
        javaMaxHeapSize "3g"
        preDexLibraries = false
    }

}

dependencies {
    testCompile 'junit:junit:4.12'
    compile 'com.android.support:support-v4:24.2.1'
    compile 'org.apache.opennlp:opennlp-maxent:3.0.3'
    compile 'org.apache.opennlp:opennlp-uima:1.5.3'
    compile 'org.apache.opennlp:opennlp-tools:1.5.3'
    compile 'com.android.support:multidex:1.0.1'
    compile 'com.ibm.icu:icu4j:57.1'
    compile fileTree(include: ['*.jar'], dir: 'libs')
    compile 'org.apache.logging.log4j:log4j:2.6.2'
    compile 'net.sf.jwordnet:jwnl:1.4_rc3'
    compile 'org.apache.commons:commons-collections4:4.1'
    compile 'org.apache.httpcomponents:httpcore-nio:4.4.5'
    compile 'org.apache.httpcomponents:httpcore:4.4.5'
}

group = 'com.marytts.android'
version = '1.0.1'

task generateSourcesJar(type: Jar) {
    from android.sourceSets.main.java.srcDirs
    classifier 'sources'
}

task generateJavaDocs(type: Javadoc) {
    source = android.sourceSets.main.java.srcDirs
    classpath += project.files(android.getBootClasspath()
            .join(File.pathSeparator))
}

task generateJavaDocsJar(type: Jar) {
    from generateJavaDocs.destinationDir
    classifier 'javadoc'
}
