Bug 1917498 - Migrate the remaining AndroidX libraries to the AC dependencies plugin and clean up the manifests. r=android-reviewers,mcarare

Differential Revision: https://phabricator.services.mozilla.com/D221415
This commit is contained in:
Ryan VanderMeulen 2024-09-09 11:30:09 +00:00
parent 6da0cb8140
commit 3ea7c0e807
8 changed files with 90 additions and 97 deletions

View File

@ -32,7 +32,7 @@ buildscript {
classpath ComponentsDependencies.tools_kotlingradle
// Used in mobile/android/fenix/app/build.gradle
classpath ComponentsDependencies.androidx_safeargs
classpath ComponentsDependencies.androidx_navigation_safeargs
classpath ComponentsDependencies.osslicenses_plugin
classpath ComponentsDependencies.tools_benchmarkgradle
classpath "org.mozilla.telemetry:glean-gradle-plugin:${Versions.mozilla_glean}"

View File

@ -56,40 +56,38 @@ object Versions {
const val activity = "1.9.2"
const val annotation = "1.8.2"
const val appcompat = "1.7.0"
const val arch = "2.2.0"
const val autofill = "1.1.0"
const val benchmark = "1.3.0"
const val browser = "1.8.0"
const val biometric = "1.1.0"
const val browser = "1.8.0"
const val cardview = "1.0.0"
const val collection = "1.4.3"
const val compose_bom = "2024.09.00"
const val constraintlayout = "2.1.4"
const val constraintlayout_compose = "1.0.1"
const val coordinatorlayout = "1.2.0"
const val core = "1.13.1"
const val core_splashscreen = "1.0.1"
const val datastore="1.1.1"
const val drawerlayout = "1.2.0"
const val fragment = "1.8.3"
const val recyclerview = "1.3.2"
const val room = "2.6.1"
const val savedstate = "1.2.1"
const val lifecycle = "2.8.5"
const val localbroadcastmanager = "1.0.0"
const val media = "1.7.0"
const val navigation = "2.7.7"
const val paging = "3.3.2"
const val palette = "1.0.0"
const val preferences = "1.2.1"
const val lifecycle = "2.8.5"
const val media = "1.7.0"
const val navigation = "2.7.7"
const val transition = "1.5.1"
const val tracing = "1.2.0"
const val work = "2.9.1"
const val arch = "2.2.0"
const val localbroadcastmanager = "1.0.0"
const val profileinstaller = "1.3.1"
const val recyclerview = "1.3.2"
const val room = "2.6.1"
const val savedstate = "1.2.1"
const val swiperefreshlayout = "1.1.0"
const val datastore="1.1.1"
const val test = "1.6.1"
const val test_ext = "1.2.1"
const val test_espresso = "3.6.1"
const val test_orchestrator = "1.5.0"
const val test_runner = "1.6.1"
const val test_uiautomator = "2.3.0"
const val tracing = "1.2.0"
const val transition = "1.5.1"
const val viewpager2 = "1.1.0"
const val work = "2.9.1"
}
object Google {
@ -102,6 +100,15 @@ object Versions {
const val play_services_base = "18.5.0"
const val play_services_fido = "21.1.0"
}
object Testing {
const val androidx_test = "1.6.1"
const val androidx_test_espresso = "3.6.1"
const val androidx_test_ext = "1.2.1"
const val androidx_test_orchestrator = "1.5.0"
const val androidx_test_runner = "1.6.1"
const val androidx_test_uiautomator = "2.3.0"
}
}
// Synchronized dependencies used by (some) modules
@ -125,9 +132,9 @@ object ComponentsDependencies {
const val androidx_activity_ktx = "androidx.activity:activity-ktx:${Versions.AndroidX.activity}"
const val androidx_annotation = "androidx.annotation:annotation:${Versions.AndroidX.annotation}"
const val androidx_appcompat = "androidx.appcompat:appcompat:${Versions.AndroidX.appcompat}"
const val androidx_autofill = "androidx.autofill:autofill:${Versions.AndroidX.autofill}"
const val androidx_arch_core_common = "androidx.arch.core:core-common:${Versions.AndroidX.arch}"
const val androidx_arch_core_testing = "androidx.arch.core:core-testing:${Versions.AndroidX.arch}"
const val androidx_autofill = "androidx.autofill:autofill:${Versions.AndroidX.autofill}"
const val androidx_benchmark_junit4 = "androidx.benchmark:benchmark-junit4:${Versions.AndroidX.benchmark}"
const val androidx_benchmark_macro_junit4 = "androidx.benchmark:benchmark-macro-junit4:${Versions.AndroidX.benchmark}"
const val androidx_biometric = "androidx.biometric:biometric:${Versions.AndroidX.biometric}"
@ -148,14 +155,14 @@ object ComponentsDependencies {
const val androidx_compose_runtime_livedata = "androidx.compose.runtime:runtime-livedata"
const val androidx_compose_runtime_saveable = "androidx.compose.runtime:runtime-saveable"
const val androidx_safeargs = "androidx.navigation:navigation-safe-args-gradle-plugin:${Versions.AndroidX.navigation}"
const val androidx_navigation_fragment = "androidx.navigation:navigation-fragment-ktx:${Versions.AndroidX.navigation}"
const val androidx_navigation_ui = "androidx.navigation:navigation-ui:${Versions.AndroidX.navigation}"
const val androidx_compose_navigation = "androidx.navigation:navigation-compose:${Versions.AndroidX.navigation}"
const val androidx_constraintlayout = "androidx.constraintlayout:constraintlayout:${Versions.AndroidX.constraintlayout}"
const val androidx_constraintlayout_compose = "androidx.constraintlayout:constraintlayout-compose:${Versions.AndroidX.constraintlayout_compose}"
const val androidx_coordinatorlayout = "androidx.coordinatorlayout:coordinatorlayout:${Versions.AndroidX.coordinatorlayout}"
const val androidx_core = "androidx.core:core:${Versions.AndroidX.core}"
const val androidx_core_ktx = "androidx.core:core-ktx:${Versions.AndroidX.core}"
const val androidx_coordinatorlayout = "androidx.coordinatorlayout:coordinatorlayout:${Versions.AndroidX.coordinatorlayout}"
const val androidx_core_splashscreen = "androidx.core:core-splashscreen:${Versions.AndroidX.core_splashscreen}"
const val androidx_datastore = "androidx.datastore:datastore:${Versions.AndroidX.datastore}"
const val androidx_datastore_preferences = "androidx.datastore:datastore-preferences:${Versions.AndroidX.datastore}"
const val androidx_drawerlayout = "androidx.drawerlayout:drawerlayout:${Versions.AndroidX.drawerlayout}"
const val androidx_fragment = "androidx.fragment:fragment:${Versions.AndroidX.fragment}"
const val androidx_lifecycle_common = "androidx.lifecycle:lifecycle-common:${Versions.AndroidX.lifecycle}"
@ -165,35 +172,39 @@ object ComponentsDependencies {
const val androidx_lifecycle_runtime = "androidx.lifecycle:lifecycle-runtime-ktx:${Versions.AndroidX.lifecycle}"
const val androidx_lifecycle_service = "androidx.lifecycle:lifecycle-service:${Versions.AndroidX.lifecycle}"
const val androidx_lifecycle_viewmodel = "androidx.lifecycle:lifecycle-viewmodel-ktx:${Versions.AndroidX.lifecycle}"
const val androidx_localbroadcastmanager = "androidx.localbroadcastmanager:localbroadcastmanager:${Versions.AndroidX.localbroadcastmanager}"
const val androidx_media = "androidx.media:media:${Versions.AndroidX.media}"
const val androidx_navigation_compose = "androidx.navigation:navigation-compose:${Versions.AndroidX.navigation}"
const val androidx_navigation_fragment = "androidx.navigation:navigation-fragment-ktx:${Versions.AndroidX.navigation}"
const val androidx_navigation_safeargs = "androidx.navigation:navigation-safe-args-gradle-plugin:${Versions.AndroidX.navigation}"
const val androidx_navigation_ui = "androidx.navigation:navigation-ui:${Versions.AndroidX.navigation}"
const val androidx_paging = "androidx.paging:paging-runtime:${Versions.AndroidX.paging}"
const val androidx_palette = "androidx.palette:palette-ktx:${Versions.AndroidX.palette}"
const val androidx_preferences = "androidx.preference:preference:${Versions.AndroidX.preferences}"
const val androidx_profileinstaller = "androidx.profileinstaller:profileinstaller:${Versions.AndroidX.profileinstaller}"
const val androidx_recyclerview = "androidx.recyclerview:recyclerview:${Versions.AndroidX.recyclerview}"
const val androidx_room_runtime = "androidx.room:room-ktx:${Versions.AndroidX.room}"
const val androidx_room_compiler = "androidx.room:room-compiler:${Versions.AndroidX.room}"
const val androidx_room_runtime = "androidx.room:room-ktx:${Versions.AndroidX.room}"
const val androidx_room_testing = "androidx.room:room-testing:${Versions.AndroidX.room}"
const val androidx_savedstate = "androidx.savedstate:savedstate:${Versions.AndroidX.savedstate}"
const val androidx_swiperefreshlayout = "androidx.swiperefreshlayout:swiperefreshlayout:${Versions.AndroidX.swiperefreshlayout}"
const val androidx_tracing = "androidx.tracing:tracing:${Versions.AndroidX.tracing}"
const val androidx_transition = "androidx.transition:transition:${Versions.AndroidX.transition}"
const val androidx_viewpager2 = "androidx.viewpager2:viewpager2:${Versions.AndroidX.viewpager2}"
const val androidx_work_runtime = "androidx.work:work-runtime:${Versions.AndroidX.work}"
const val androidx_work_testing = "androidx.work:work-testing:${Versions.AndroidX.work}"
const val androidx_localbroadcastmanager = "androidx.localbroadcastmanager:localbroadcastmanager:${Versions.AndroidX.localbroadcastmanager}"
const val androidx_swiperefreshlayout = "androidx.swiperefreshlayout:swiperefreshlayout:${Versions.AndroidX.swiperefreshlayout}"
const val androidx_datastore = "androidx.datastore:datastore:${Versions.AndroidX.datastore}"
const val androidx_datastore_preferences = "androidx.datastore:datastore-preferences:${Versions.AndroidX.datastore}"
const val androidx_espresso_contrib = "androidx.test.espresso:espresso-contrib:${Versions.AndroidX.test_espresso}"
const val androidx_espresso_core = "androidx.test.espresso:espresso-core:${Versions.AndroidX.test_espresso}"
const val androidx_espresso_idling_resource = "androidx.test.espresso:espresso-idling-resource:${Versions.AndroidX.test_espresso}"
const val androidx_espresso_intents = "androidx.test.espresso:espresso-intents:${Versions.AndroidX.test_espresso}"
const val androidx_espresso_web = "androidx.test.espresso:espresso-web:${Versions.AndroidX.test_espresso}"
const val androidx_test_core = "androidx.test:core-ktx:${Versions.AndroidX.test}"
const val androidx_test_junit = "androidx.test.ext:junit-ktx:${Versions.AndroidX.test_ext}"
const val androidx_test_orchestrator = "androidx.test:orchestrator:${Versions.AndroidX.test_orchestrator}"
const val androidx_test_runner = "androidx.test:runner:${Versions.AndroidX.test_runner}"
const val androidx_test_rules = "androidx.test:rules:${Versions.AndroidX.test}"
const val androidx_test_uiautomator = "androidx.test.uiautomator:uiautomator:${Versions.AndroidX.test_uiautomator}"
const val androidx_espresso_contrib = "androidx.test.espresso:espresso-contrib:${Versions.Testing.androidx_test_espresso}"
const val androidx_espresso_core = "androidx.test.espresso:espresso-core:${Versions.Testing.androidx_test_espresso}"
const val androidx_espresso_idling_resource = "androidx.test.espresso:espresso-idling-resource:${Versions.Testing.androidx_test_espresso}"
const val androidx_espresso_intents = "androidx.test.espresso:espresso-intents:${Versions.Testing.androidx_test_espresso}"
const val androidx_espresso_web = "androidx.test.espresso:espresso-web:${Versions.Testing.androidx_test_espresso}"
const val androidx_test_core = "androidx.test:core-ktx:${Versions.Testing.androidx_test}"
const val androidx_test_junit = "androidx.test.ext:junit-ktx:${Versions.Testing.androidx_test_ext}"
const val androidx_test_orchestrator = "androidx.test:orchestrator:${Versions.Testing.androidx_test_orchestrator}"
const val androidx_test_runner = "androidx.test:runner:${Versions.Testing.androidx_test_runner}"
const val androidx_test_rules = "androidx.test:rules:${Versions.Testing.androidx_test}"
const val androidx_test_uiautomator = "androidx.test.uiautomator:uiautomator:${Versions.Testing.androidx_test_uiautomator}"
const val google_material = "com.google.android.material:material:${Versions.Google.material}"

View File

@ -79,7 +79,7 @@ dependencies {
implementation ComponentsDependencies.androidx_compose_ui_tooling
implementation ComponentsDependencies.androidx_compose_foundation
implementation ComponentsDependencies.androidx_compose_material
implementation ComponentsDependencies.androidx_compose_navigation
implementation ComponentsDependencies.androidx_navigation_compose
}
preBuild.dependsOn updateBorderifyExtensionVersion

View File

@ -549,17 +549,11 @@ tasks.withType(KotlinCompile).configureEach {
dependencies {
implementation ComponentsDependencies.kotlin_json
implementation platform(ComponentsDependencies.androidx_compose_bom)
androidTestImplementation platform(ComponentsDependencies.androidx_compose_bom)
implementation project(':browser-engine-gecko')
implementation ComponentsDependencies.kotlin_coroutines
testImplementation ComponentsDependencies.testing_coroutines
implementation ComponentsDependencies.accompanist_drawablepainter
implementation ComponentsDependencies.androidx_appcompat
implementation ComponentsDependencies.androidx_constraintlayout
implementation ComponentsDependencies.androidx_coordinatorlayout
implementation ComponentsDependencies.thirdparty_sentry
@ -661,36 +655,43 @@ dependencies {
implementation ComponentsDependencies.androidx_activity
implementation ComponentsDependencies.androidx_activity_ktx
implementation ComponentsDependencies.androidx_annotation
implementation ComponentsDependencies.androidx_compose_ui
implementation ComponentsDependencies.androidx_compose_ui_tooling_preview
implementation ComponentsDependencies.androidx_appcompat
implementation ComponentsDependencies.androidx_biometric
implementation platform(ComponentsDependencies.androidx_compose_bom)
androidTestImplementation platform(ComponentsDependencies.androidx_compose_bom)
implementation ComponentsDependencies.androidx_compose_animation
implementation ComponentsDependencies.androidx_compose_foundation
implementation ComponentsDependencies.androidx_compose_material
implementation ComponentsDependencies.androidx_biometric
implementation ComponentsDependencies.androidx_paging
implementation ComponentsDependencies.androidx_preferences
implementation ComponentsDependencies.androidx_fragment
implementation ComponentsDependencies.androidx_navigation_fragment
implementation ComponentsDependencies.androidx_navigation_ui
implementation ComponentsDependencies.androidx_compose_navigation
implementation ComponentsDependencies.androidx_recyclerview
implementation ComponentsDependencies.androidx_swiperefreshlayout
implementation ComponentsDependencies.androidx_compose_ui
implementation ComponentsDependencies.androidx_compose_ui_tooling_preview
implementation ComponentsDependencies.androidx_constraintlayout
implementation ComponentsDependencies.androidx_coordinatorlayout
implementation ComponentsDependencies.androidx_core
implementation ComponentsDependencies.androidx_core_ktx
implementation ComponentsDependencies.androidx_core_splashscreen
implementation ComponentsDependencies.androidx_datastore
implementation ComponentsDependencies.androidx_datastore_preferences
implementation ComponentsDependencies.androidx_fragment
implementation ComponentsDependencies.androidx_lifecycle_common
implementation ComponentsDependencies.androidx_lifecycle_livedata
implementation ComponentsDependencies.androidx_lifecycle_process
implementation ComponentsDependencies.androidx_lifecycle_runtime
implementation ComponentsDependencies.androidx_lifecycle_viewmodel
implementation ComponentsDependencies.androidx_lifecycle_service
implementation ComponentsDependencies.androidx_core
implementation ComponentsDependencies.androidx_core_ktx
implementation FenixDependencies.androidx_core_splashscreen
implementation ComponentsDependencies.androidx_lifecycle_viewmodel
implementation ComponentsDependencies.androidx_navigation_compose
implementation ComponentsDependencies.androidx_navigation_fragment
implementation ComponentsDependencies.androidx_navigation_ui
implementation ComponentsDependencies.androidx_paging
implementation ComponentsDependencies.androidx_preferences
implementation ComponentsDependencies.androidx_profileinstaller
implementation ComponentsDependencies.androidx_recyclerview
implementation ComponentsDependencies.androidx_swiperefreshlayout
implementation ComponentsDependencies.androidx_transition
implementation FenixDependencies.androidx_viewpager2
implementation ComponentsDependencies.androidx_viewpager2
implementation ComponentsDependencies.androidx_work_runtime
implementation ComponentsDependencies.androidx_datastore
implementation ComponentsDependencies.androidx_datastore_preferences
implementation FenixDependencies.protobuf_javalite
implementation ComponentsDependencies.google_material
@ -704,8 +705,6 @@ dependencies {
implementation ComponentsDependencies.play_review
implementation ComponentsDependencies.play_review_ktx
implementation FenixDependencies.androidx_profileinstaller
constraints {
implementation (ComponentsDependencies.androidx_tracing) {
because 'AndroidX Test gets force-downgraded to 1.0.0 and breaks otherwise'

View File

@ -24,7 +24,7 @@ buildscript {
classpath ComponentsDependencies.tools_androidgradle
classpath ComponentsDependencies.tools_benchmarkgradle
classpath ComponentsDependencies.tools_kotlingradle
classpath ComponentsDependencies.androidx_safeargs
classpath ComponentsDependencies.androidx_navigation_safeargs
classpath ComponentsDependencies.osslicenses_plugin
classpath "org.mozilla.telemetry:glean-gradle-plugin:${Versions.mozilla_glean}"
classpath "${ApplicationServicesConfig.groupId}:tooling-nimbus-gradle:${ApplicationServicesConfig.version}"

View File

@ -16,10 +16,6 @@ object FenixVersions {
const val falcon = "2.2.0"
const val fastlane = "2.1.1"
const val androidx_profileinstaller = "1.3.1"
const val androidx_splash_screen = "1.0.1"
const val androidx_viewpager2 = "1.1.0"
const val adjust = "4.38.2"
const val installreferrer = "2.2"
@ -33,10 +29,6 @@ object FenixVersions {
@Suppress("unused")
object FenixDependencies {
const val androidx_core_splashscreen = "androidx.core:core-splashscreen:${FenixVersions.androidx_splash_screen}"
const val androidx_profileinstaller = "androidx.profileinstaller:profileinstaller:${FenixVersions.androidx_profileinstaller}"
const val androidx_viewpager2 = "androidx.viewpager2:viewpager2:${FenixVersions.androidx_viewpager2}"
const val protobuf_javalite = "com.google.protobuf:protobuf-javalite:${FenixVersions.protobuf}"
const val protobuf_compiler = "com.google.protobuf:protoc:${FenixVersions.protobuf}"

View File

@ -231,22 +231,25 @@ nimbus {
}
dependencies {
implementation platform(ComponentsDependencies.androidx_compose_bom)
androidTestImplementation platform(ComponentsDependencies.androidx_compose_bom)
implementation ComponentsDependencies.androidx_activity
implementation ComponentsDependencies.androidx_appcompat
implementation ComponentsDependencies.androidx_browser
implementation ComponentsDependencies.androidx_cardview
implementation ComponentsDependencies.androidx_collection
implementation ComponentsDependencies.androidx_compose_ui
implementation ComponentsDependencies.androidx_compose_ui_tooling
implementation platform(ComponentsDependencies.androidx_compose_bom)
androidTestImplementation platform(ComponentsDependencies.androidx_compose_bom)
implementation ComponentsDependencies.androidx_compose_foundation
implementation ComponentsDependencies.androidx_compose_material
implementation ComponentsDependencies.androidx_compose_runtime_livedata
implementation ComponentsDependencies.androidx_compose_ui
implementation ComponentsDependencies.androidx_compose_ui_tooling
implementation ComponentsDependencies.androidx_constraintlayout
implementation FocusDependencies.androidx_constraint_layout_compose
implementation ComponentsDependencies.androidx_constraintlayout_compose
implementation ComponentsDependencies.androidx_core_ktx
implementation ComponentsDependencies.androidx_core_splashscreen
implementation ComponentsDependencies.androidx_datastore_preferences
implementation ComponentsDependencies.androidx_fragment
implementation ComponentsDependencies.androidx_lifecycle_process
implementation ComponentsDependencies.androidx_lifecycle_viewmodel
@ -254,10 +257,8 @@ dependencies {
implementation ComponentsDependencies.androidx_preferences
implementation ComponentsDependencies.androidx_recyclerview
implementation ComponentsDependencies.androidx_savedstate
implementation FocusDependencies.androidx_splashscreen
implementation ComponentsDependencies.androidx_transition
implementation ComponentsDependencies.androidx_work_runtime
implementation ComponentsDependencies.androidx_datastore_preferences
// Required for in-app reviews
implementation ComponentsDependencies.play_review

View File

@ -18,11 +18,6 @@ object FocusVersions {
const val install_referrer = "2.2"
}
object AndroidX {
const val constraint_layout_compose = "1.0.1"
const val splashscreen = "1.0.1"
}
object Testing {
const val falcon = "2.2.0"
const val fastlane = "2.1.1"
@ -31,11 +26,6 @@ object FocusVersions {
}
object FocusDependencies {
const val androidx_constraint_layout_compose =
"androidx.constraintlayout:constraintlayout-compose:${FocusVersions.AndroidX.constraint_layout_compose}"
const val androidx_splashscreen = "androidx.core:core-splashscreen:${FocusVersions.AndroidX.splashscreen}"
const val adjust = "com.adjust.sdk:adjust-android:${FocusVersions.Adjust.adjust}"
const val install_referrer = "com.android.installreferrer:installreferrer:${FocusVersions.Adjust.install_referrer}"