diff options
| author | 3gg <3gg@shellblade.net> | 2025-12-27 12:03:39 -0800 |
|---|---|---|
| committer | 3gg <3gg@shellblade.net> | 2025-12-27 12:03:39 -0800 |
| commit | 5a079a2d114f96d4847d1ee305d5b7c16eeec50e (patch) | |
| tree | 8926ab44f168acf787d8e19608857b3af0f82758 /contrib/SDL-3.2.8/android-project/app/build.gradle | |
Initial commit
Diffstat (limited to 'contrib/SDL-3.2.8/android-project/app/build.gradle')
| -rw-r--r-- | contrib/SDL-3.2.8/android-project/app/build.gradle | 62 |
1 files changed, 62 insertions, 0 deletions
diff --git a/contrib/SDL-3.2.8/android-project/app/build.gradle b/contrib/SDL-3.2.8/android-project/app/build.gradle new file mode 100644 index 0000000..8946de6 --- /dev/null +++ b/contrib/SDL-3.2.8/android-project/app/build.gradle | |||
| @@ -0,0 +1,62 @@ | |||
| 1 | plugins { | ||
| 2 | id 'com.android.application' | ||
| 3 | } | ||
| 4 | |||
| 5 | def buildWithCMake = project.hasProperty('BUILD_WITH_CMAKE'); | ||
| 6 | |||
| 7 | android { | ||
| 8 | namespace "org.libsdl.app" | ||
| 9 | compileSdkVersion 35 | ||
| 10 | defaultConfig { | ||
| 11 | minSdkVersion 21 | ||
| 12 | targetSdkVersion 35 | ||
| 13 | versionCode 1 | ||
| 14 | versionName "1.0" | ||
| 15 | externalNativeBuild { | ||
| 16 | ndkBuild { | ||
| 17 | arguments "APP_PLATFORM=android-19" | ||
| 18 | // abiFilters 'armeabi-v7a', 'arm64-v8a', 'x86', 'x86_64' | ||
| 19 | abiFilters 'arm64-v8a' | ||
| 20 | } | ||
| 21 | cmake { | ||
| 22 | arguments "-DANDROID_PLATFORM=android-19", "-DANDROID_STL=c++_static" | ||
| 23 | // abiFilters 'armeabi-v7a', 'arm64-v8a', 'x86', 'x86_64' | ||
| 24 | abiFilters 'arm64-v8a' | ||
| 25 | } | ||
| 26 | } | ||
| 27 | } | ||
| 28 | buildTypes { | ||
| 29 | release { | ||
| 30 | minifyEnabled false | ||
| 31 | proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' | ||
| 32 | } | ||
| 33 | } | ||
| 34 | applicationVariants.all { variant -> | ||
| 35 | tasks["merge${variant.name.capitalize()}Assets"] | ||
| 36 | .dependsOn("externalNativeBuild${variant.name.capitalize()}") | ||
| 37 | } | ||
| 38 | if (!project.hasProperty('EXCLUDE_NATIVE_LIBS')) { | ||
| 39 | sourceSets.main { | ||
| 40 | jniLibs.srcDir 'libs' | ||
| 41 | } | ||
| 42 | externalNativeBuild { | ||
| 43 | if (buildWithCMake) { | ||
| 44 | cmake { | ||
| 45 | path 'jni/CMakeLists.txt' | ||
| 46 | } | ||
| 47 | } else { | ||
| 48 | ndkBuild { | ||
| 49 | path 'jni/Android.mk' | ||
| 50 | } | ||
| 51 | } | ||
| 52 | } | ||
| 53 | |||
| 54 | } | ||
| 55 | lint { | ||
| 56 | abortOnError false | ||
| 57 | } | ||
| 58 | } | ||
| 59 | |||
| 60 | dependencies { | ||
| 61 | implementation fileTree(include: ['*.jar'], dir: 'libs') | ||
| 62 | } | ||
