apply plugin: 'com.android.application'

def android_arch = System.getenv("ANDROID_ARCH")
def abi_filters = android_arch != null ? [android_arch] : ['armeabi-v7a', 'arm64-v8a']

android {
    compileSdkVersion 34

    defaultConfig {
        applicationId 		'DE.Android.Tests'
        targetSdkVersion 	32
        minSdkVersion 		28

        ndk {
            abiFilters = []
            abiFilters.addAll(abi_filters)
        }
        externalNativeBuild {
            cmake {
                arguments '-DANDROID_STL=c++_static',
						  '-DDILIGENT_NO_FORMAT_VALIDATION=ON'
            }
        }
    }

    buildTypes {
        release {
            //debuggable true // to enable logcat in release
            minifyEnabled = false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }

    ndkVersion "27.0.12077973"

    externalNativeBuild {
        cmake {
            version '3.22.1'
            path 'src/main/jni/CMakeLists.txt'
        }
    }
    namespace 'DE.Android.Tests'
}
