apply plugin: 'com.android.library' allprojects { gradle.projectsEvaluated { tasks.withType(JavaCompile) { options.encoding = 'utf-8' options.compilerArgs << "-Xlint:deprecation" } } } buildscript { repositories { google() jcenter() } dependencies { classpath 'com.android.tools.build:gradle:3.1.2' } } def DEFAULT_COMPILE_SDK_VERSION = 27 def DEFAULT_BUILD_TOOLS_VERSION = "27.0.3" def DEFAULT_TARGET_SDK_VERSION = 27 def DEFAULT_ANDROID_SUPPORT_VERSION = "27.1.0" android { compileSdkVersion rootProject.hasProperty('compileSdkVersion') ? rootProject.compileSdkVersion : DEFAULT_COMPILE_SDK_VERSION buildToolsVersion rootProject.hasProperty('buildToolsVersion') ? rootProject.buildToolsVersion : DEFAULT_BUILD_TOOLS_VERSION defaultConfig { minSdkVersion 16 targetSdkVersion rootProject.hasProperty('targetSdkVersion') ? rootProject.targetSdkVersion : DEFAULT_TARGET_SDK_VERSION versionCode 1 versionName "1.0" testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" } buildTypes { release { minifyEnabled false proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' } } splits { abi { enable true reset() include "armeabi-v7a", "arm64-v8a", "x86", "x86_64" // Specify that we do not want an additional universal SDK universalApk false } } } dependencies { def androidSupportVersion = rootProject.hasProperty("androidSupportVersion") ? rootProject.androidSupportVersion : DEFAULT_ANDROID_SUPPORT_VERSION // from internet implementation "com.android.support:appcompat-v7:$androidSupportVersion" implementation "io.agora.rtc:full-sdk:2.9.4" // from node_modules implementation "com.facebook.react:react-native:+" } repositories { mavenCentral() mavenLocal() maven { url "$rootDir/../node_modules/react-native-agora/android" } jcenter() google() }