apply plugin: 'com.android.application'

android {
    compileSdkVersion 29
    buildToolsVersion "29.0.2"
    defaultConfig {
        applicationId "com.example.http"
        minSdkVersion 15
        targetSdkVersion 29
        versionCode 1
        versionName "1.0"
        testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
        externalNativeBuild {
            cmake {
                cppFlags ""
                arguments "-DANDROID_STL=c++_shared"
                //arguments "-DANDROID_STL=gnustl_shared"
                arguments "-DCMAKE_BUILD_TYPE=RELEASE"
                //arguments "-DCMAKE_BUILD_TYPE=DEBUG"
                arguments "-DCMAKE_CXX_FLAGS_RELEASE=-O3"
                arguments "-DCMAKE_VERBOSE_MAKEFILE=ON"
                //abiFilters 'armeabi', 'arm64-v8a', 'armeabi-v7a', 'x86'//, 'x86_64'
                abiFilters 'arm64-v8a', 'armeabi-v7a', 'x86' //, 'x86_64'
            }
        }
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
        }
    }
    externalNativeBuild {
        cmake {
            path "src/main/cpp/CMakeLists.txt"
            version "3.10.2"
        }
    }

    packagingOptions {
        doNotStrip "*/armeabi/*.so"
        doNotStrip "*/arm64-v8a/*.so"
        doNotStrip "*/armeabi-v7a/*.so"
        doNotStrip "*/x86/*.so"
        doNotStrip "*/x86_64/*.so"
    }
}

repositories {
    flatDir {
        dirs 'libs'
    }
}

dependencies {
    implementation fileTree(dir: 'libs', include: ['*.jar'])
    //implementation(name:'acl-debug', ext:'aar')
    implementation 'androidx.appcompat:appcompat:1.1.0'
    implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
    testImplementation 'junit:junit:4.12'
    androidTestImplementation 'androidx.test:runner:1.2.0'
    androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'
}
