From 1db19553243e9de42cafe311d334430eb717eeb5 Mon Sep 17 00:00:00 2001 From: Gerhard Olsson Date: Sat, 8 Jun 2024 19:29:33 +0200 Subject: [PATCH] Disable wear Google Play requires update from the ancient play wear version, which requires migration to the ancient (non-bundled) wear interface. The wear app was not built as it was. --- app/build.gradle | 7 +++++++ .../org/runnerup/tracker/component/TrackerWear.java | 0 .../org/runnerup/tracker/component/TrackerWear.java | 0 build.gradle | 7 ++++--- 4 files changed, 11 insertions(+), 3 deletions(-) rename app/src/{free => nonwear}/org/runnerup/tracker/component/TrackerWear.java (100%) rename app/src/{play => wear}/org/runnerup/tracker/component/TrackerWear.java (100%) diff --git a/app/build.gradle b/app/build.gradle index a9b8d641d..287bc76ce 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -19,8 +19,15 @@ android { java.srcDirs = ['src/main'] if (rootProject.ext.allowNonFree) { java.srcDirs += ['src/play'] + if (rootProject.ext.enableWear) { + java.srcDirs += ['src/wear'] + } + else { + java.srcDirs += ['src/nonwear'] + } } else { java.srcDirs += ['src/free'] + java.srcDirs += ['src/nonwear'] } resources.srcDirs = java.srcDirs aidl.srcDirs = java.srcDirs diff --git a/app/src/free/org/runnerup/tracker/component/TrackerWear.java b/app/src/nonwear/org/runnerup/tracker/component/TrackerWear.java similarity index 100% rename from app/src/free/org/runnerup/tracker/component/TrackerWear.java rename to app/src/nonwear/org/runnerup/tracker/component/TrackerWear.java diff --git a/app/src/play/org/runnerup/tracker/component/TrackerWear.java b/app/src/wear/org/runnerup/tracker/component/TrackerWear.java similarity index 100% rename from app/src/play/org/runnerup/tracker/component/TrackerWear.java rename to app/src/wear/org/runnerup/tracker/component/TrackerWear.java diff --git a/build.gradle b/build.gradle index 8d0333fc3..72f0c9f31 100644 --- a/build.gradle +++ b/build.gradle @@ -23,8 +23,8 @@ project.ext { appcompat_version = "1.7.0" annotation_version = "1.6.0" preference_version = "1.2.1" - //Note: Later Play Services will require a rewrite of NodeApi.NodeListener - googlePlayServicesVersion = '11.0.4' + //Note: Play Services later than 11.0.4 disables wear, requires a rewrite of NodeApi.NodeListener + googlePlayServicesVersion = '21.3.0' googleWearVersion = '2.9.0' junitVersion = '4.13.2' @@ -37,7 +37,8 @@ project.ext { // F-Droid builds only allow free software (wear dir deleted at builds) allowNonFree = !project.hasProperty('org.runnerup.free') && rootProject.file("wear").exists() - enableWear = allowNonFree + // wear disabled, requires Play services migration + enableWear = false // Note: AntPlus may have to be downloaded explicitly due to licensing // Therefore, the .aar file may not be redistributed in the RU repo