diff --git a/app/build.gradle.kts b/app/build.gradle.kts index c8dc305..83eb2a7 100644 --- a/app/build.gradle.kts +++ b/app/build.gradle.kts @@ -1,3 +1,6 @@ +import java.util.Properties +import java.io.FileInputStream + plugins { alias(libs.plugins.android.application) alias(libs.plugins.kotlin.compose) @@ -14,20 +17,41 @@ android { defaultConfig { applicationId = "swiss.qpq.gajumobile" - minSdk = 34 + minSdk = 26 targetSdk = 36 versionCode = 1 - versionName = "1.0" + versionName = "0.1" testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner" externalNativeBuild { cmake { cppFlags("") + // 16 KB page alignment for Android 15/16+ + arguments("-DCMAKE_SHARED_LINKER_FLAGS=-Wl,-z,max-page-size=16384") } } } + val keystorePropertiesFile = rootProject.file("local.properties") + val keystoreProperties = Properties() + if (keystorePropertiesFile.exists()) { + keystoreProperties.load(FileInputStream(keystorePropertiesFile)) + } + + signingConfigs { + create("release") { + storeFile = keystoreProperties.getProperty("release.store.file")?.trim()?.removeSurrounding("\"")?.let { file(it) } + storePassword = keystoreProperties.getProperty("release.store.password")?.trim()?.removeSurrounding("\"") + keyAlias = keystoreProperties.getProperty("release.key.alias")?.trim()?.removeSurrounding("\"") + keyPassword = keystoreProperties.getProperty("release.key.password")?.trim()?.removeSurrounding("\"") + enableV1Signing = true + enableV2Signing = true + enableV3Signing = true + enableV4Signing = true + } + } + externalNativeBuild { cmake { path = file("src/main/cpp/CMakeLists.txt") @@ -37,6 +61,12 @@ android { buildTypes { release { + if (signingConfigs.getByName("release").storeFile != null) { + signingConfig = signingConfigs.getByName("release") + } + isDebuggable = false + // Ensure no testOnly attribute is added + optimization { enable = false } @@ -61,6 +91,15 @@ android { } } +androidComponents { + onVariants { variant -> + variant.outputs.forEach { output -> + // This sets the filename for both debug and release + output.outputFileName.set("GajuMobile-${android.defaultConfig.versionName}-Android.apk") + } + } +} + dependencies { implementation(platform(libs.androidx.compose.bom)) implementation(libs.androidx.activity.compose) diff --git a/app/release/GajuMobile-0.1-Android.apk b/app/release/GajuMobile-0.1-Android.apk new file mode 100644 index 0000000..b038e90 Binary files /dev/null and b/app/release/GajuMobile-0.1-Android.apk differ diff --git a/app/release/baselineProfiles/0/GajuMobile-0.1-Android.dm b/app/release/baselineProfiles/0/GajuMobile-0.1-Android.dm new file mode 100644 index 0000000..fe8273d Binary files /dev/null and b/app/release/baselineProfiles/0/GajuMobile-0.1-Android.dm differ diff --git a/app/release/baselineProfiles/1/GajuMobile-0.1-Android.dm b/app/release/baselineProfiles/1/GajuMobile-0.1-Android.dm new file mode 100644 index 0000000..7fe4859 Binary files /dev/null and b/app/release/baselineProfiles/1/GajuMobile-0.1-Android.dm differ diff --git a/app/release/output-metadata.json b/app/release/output-metadata.json new file mode 100644 index 0000000..9230c71 --- /dev/null +++ b/app/release/output-metadata.json @@ -0,0 +1,37 @@ +{ + "version": 3, + "artifactType": { + "type": "APK", + "kind": "Directory" + }, + "applicationId": "swiss.qpq.gajumobile", + "variantName": "release", + "elements": [ + { + "type": "SINGLE", + "filters": [], + "attributes": [], + "versionCode": 1, + "versionName": "0.1", + "outputFile": "GajuMobile-0.1-Android.apk" + } + ], + "elementType": "File", + "baselineProfiles": [ + { + "minApi": 28, + "maxApi": 30, + "baselineProfiles": [ + "baselineProfiles/1/GajuMobile-0.1-Android.dm" + ] + }, + { + "minApi": 31, + "maxApi": 2147483647, + "baselineProfiles": [ + "baselineProfiles/0/GajuMobile-0.1-Android.dm" + ] + } + ], + "minSdkVersionForDexing": 34 +} \ No newline at end of file diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index d20b8a5..cb19211 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -7,9 +7,9 @@ android:allowBackup="false" android:dataExtractionRules="@xml/data_extraction_rules" android:fullBackupContent="false" - android:icon="@mipmap/ic_launcher" + android:icon="@mipmap/ic_gaju_launcher" android:label="@string/app_name" - android:roundIcon="@mipmap/ic_launcher_round" + android:roundIcon="@mipmap/ic_gaju_launcher_round" android:supportsRtl="true" android:theme="@style/Theme.GajuMobile" android:usesCleartextTraffic="true"> @@ -19,13 +19,13 @@ - diff --git a/app/src/main/res/drawable/ic_launcher_background.xml b/app/src/main/res/drawable/ic_launcher_background.xml index 07d5da9..b5cd46e 100644 --- a/app/src/main/res/drawable/ic_launcher_background.xml +++ b/app/src/main/res/drawable/ic_launcher_background.xml @@ -5,166 +5,6 @@ android:viewportWidth="108" android:viewportHeight="108"> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/app/src/main/res/drawable/ic_launcher_foreground.xml b/app/src/main/res/drawable/ic_launcher_foreground.xml deleted file mode 100644 index 2b068d1..0000000 --- a/app/src/main/res/drawable/ic_launcher_foreground.xml +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - - - \ No newline at end of file diff --git a/app/src/main/res/drawable/ic_launcher_foreground_themed.xml b/app/src/main/res/drawable/ic_launcher_foreground_themed.xml new file mode 100644 index 0000000..97ecedb --- /dev/null +++ b/app/src/main/res/drawable/ic_launcher_foreground_themed.xml @@ -0,0 +1,7 @@ + + diff --git a/app/src/main/res/mipmap-anydpi/ic_launcher.xml b/app/src/main/res/mipmap-anydpi/ic_gaju_launcher.xml similarity index 87% rename from app/src/main/res/mipmap-anydpi/ic_launcher.xml rename to app/src/main/res/mipmap-anydpi/ic_gaju_launcher.xml index 6f3b755..3b80d40 100644 --- a/app/src/main/res/mipmap-anydpi/ic_launcher.xml +++ b/app/src/main/res/mipmap-anydpi/ic_gaju_launcher.xml @@ -1,6 +1,6 @@ - - - \ No newline at end of file + + + diff --git a/app/src/main/res/mipmap-anydpi/ic_launcher_round.xml b/app/src/main/res/mipmap-anydpi/ic_gaju_launcher_round.xml similarity index 87% rename from app/src/main/res/mipmap-anydpi/ic_launcher_round.xml rename to app/src/main/res/mipmap-anydpi/ic_gaju_launcher_round.xml index 6f3b755..3b80d40 100644 --- a/app/src/main/res/mipmap-anydpi/ic_launcher_round.xml +++ b/app/src/main/res/mipmap-anydpi/ic_gaju_launcher_round.xml @@ -1,6 +1,6 @@ - - - \ No newline at end of file + + + diff --git a/app/src/main/res/mipmap-hdpi/ic_launcher.webp b/app/src/main/res/mipmap-hdpi/ic_launcher.webp deleted file mode 100644 index c209e78..0000000 Binary files a/app/src/main/res/mipmap-hdpi/ic_launcher.webp and /dev/null differ diff --git a/app/src/main/res/mipmap-hdpi/ic_launcher_round.webp b/app/src/main/res/mipmap-hdpi/ic_launcher_round.webp deleted file mode 100644 index b2dfe3d..0000000 Binary files a/app/src/main/res/mipmap-hdpi/ic_launcher_round.webp and /dev/null differ diff --git a/app/src/main/res/mipmap-mdpi/ic_launcher.webp b/app/src/main/res/mipmap-mdpi/ic_launcher.webp deleted file mode 100644 index 4f0f1d6..0000000 Binary files a/app/src/main/res/mipmap-mdpi/ic_launcher.webp and /dev/null differ diff --git a/app/src/main/res/mipmap-mdpi/ic_launcher_round.webp b/app/src/main/res/mipmap-mdpi/ic_launcher_round.webp deleted file mode 100644 index 62b611d..0000000 Binary files a/app/src/main/res/mipmap-mdpi/ic_launcher_round.webp and /dev/null differ diff --git a/app/src/main/res/mipmap-xhdpi/ic_launcher.webp b/app/src/main/res/mipmap-xhdpi/ic_launcher.webp deleted file mode 100644 index 948a307..0000000 Binary files a/app/src/main/res/mipmap-xhdpi/ic_launcher.webp and /dev/null differ diff --git a/app/src/main/res/mipmap-xhdpi/ic_launcher_round.webp b/app/src/main/res/mipmap-xhdpi/ic_launcher_round.webp deleted file mode 100644 index 1b9a695..0000000 Binary files a/app/src/main/res/mipmap-xhdpi/ic_launcher_round.webp and /dev/null differ diff --git a/app/src/main/res/mipmap-xxhdpi/ic_launcher.webp b/app/src/main/res/mipmap-xxhdpi/ic_launcher.webp deleted file mode 100644 index 28d4b77..0000000 Binary files a/app/src/main/res/mipmap-xxhdpi/ic_launcher.webp and /dev/null differ diff --git a/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.webp b/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.webp deleted file mode 100644 index 9287f50..0000000 Binary files a/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.webp and /dev/null differ diff --git a/app/src/main/res/mipmap-xxxhdpi/ic_launcher.webp b/app/src/main/res/mipmap-xxxhdpi/ic_launcher.webp deleted file mode 100644 index aa7d642..0000000 Binary files a/app/src/main/res/mipmap-xxxhdpi/ic_launcher.webp and /dev/null differ diff --git a/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.webp b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.webp deleted file mode 100644 index 9126ae3..0000000 Binary files a/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.webp and /dev/null differ