Appendix A: Example build.grade

apply plugin: 'com.android.application'

repositories {
    maven {
        url 'https://leiainc.jfrog.io/leiainc/gradle-release-local'
    }
}

android {
    compileSdkVersion 23
    defaultConfig {
        applicationId 'com.sample.teapot'
        minSdkVersion 23
        targetSdkVersion 23
        ndk {
            abiFilters 'armeabi-v7a', 'arm64-v8a'
        }
        externalNativeBuild {
            cmake {
                cppFlags "-std=c++11 -stdlib=libc++ -O2"
                arguments '-DANDROID_PLATFORM=android-21',
                        '-DANDROID_TOOLCHAIN=clang', '-DANDROID_STL=c++_static'
            }
        }
    }
    buildTypes {
        release {
            minifyEnabled = false
            proguardFiles getDefaultProguardFile('proguard-android.txt'),
                    'proguard-rules.pro'
        }
    }
    externalNativeBuild {
        cmake {
            path 'src/main/cpp/CMakeLists.txt'
        }
    }
    sourceSets {
        main {
            jniLibs.srcDirs = ['./../distribution/leia_sdk/lib']
        }
    }
}
dependencies {
    compile 'com.android.support:appcompat-v7:23.4.0'
    compile 'com.android.support.constraint:constraint-layout:1.0.2'
    
    compile 'com.leia:display:6.1.1'
}

Last updated

Copyright © 2023 Leia Inc. All Rights Reserved