Commit graph

69 commits

Author SHA1 Message Date
6703faaae2 [android] Update NDK to r27c
Signed-off-by: Konstantin Pastbin <konstantin.pastbin@gmail.com>
2025-02-04 19:35:00 +03:00
49fce04798 [android] Update dependencies
Signed-off-by: Konstantin Pastbin <konstantin.pastbin@gmail.com>
2025-02-04 19:35:00 +03:00
6c1b069de7 [android] Update AGP to 8.7.3
Signed-off-by: Konstantin Pastbin <konstantin.pastbin@gmail.com>
2025-02-04 19:35:00 +03:00
e00f33a076 [github] Manage private secrets with GitHub Secrets to enhance security
1. Restore the original simple version of `configure.sh`
   Restores 08e37f4 "Refactor configure.sh"
   Reverts b87ee95b "Fixed configure.sh script and gh actions"

2. Use GitHub Secrets instead of a private git repository to enhance
   security standards and ensure credentials are encrypted and safely
   managed.

3. Document credentials used by GitHub Actions in docs/CREDENTIALS.md

4. Include `network_security_config.xml` directly into the repo
   as it has nothing sensitive.

5. Include Apple WWDR intermediate certificates directly into the repo
   as they are not sensitive and publicly available.
   https://developer.apple.com/help/account/reference/wwdr-intermediate-certificates

6. Add `private.h` in the repository since it does not differ from
   `private_defaults.h`.

Signed-off-by: Roman Tsisyk <roman@tsisyk.com>
2024-12-27 20:16:52 +00:00
Andrew Shkrob
7be367cec5 [android-auto] Update CarApp lib to 1.7.0-beta03
Signed-off-by: Andrew Shkrob <andrew.shkrob.social@yandex.by>
2024-12-27 19:54:36 +00:00
1a9d5e32eb [android] Require cmake 3.22.1+
Reverts forced version upgrade in #9377.
(a higher version is not necessary)

Signed-off-by: Konstantin Pastbin <konstantin.pastbin@gmail.com>
2024-12-01 13:18:58 +03:00
Viktor Govako
a0f0b69e48 [gradle] Push release into the "production" track.
Signed-off-by: Viktor Govako <viktor.govako@gmail.com>
2024-11-27 09:42:10 -03:00
Atemu
7d7631cece [android] use µG play-services-location in fdroid flavour
This is a FOSS re-implementation of google's play-services-location client
library by the µG project. Because it's Apache-2.0 licensed, this ought to be
permitted on F-droid but I'm not sure whether it'd be marked with the non-free
net anti-feature.

Theoretically it should work just as well on devices with Google's GMS but I'd
suggest testing this in the fdroid flavour first where there is no alternative
and switch all flavors over if that works on actual user devices. Doing so would
remove one major blocker towards achieving
https://github.com/organicmaps/organicmaps/issues/6906.

I have tested this on LineageOS with µG and on GrapheneOS with Google GMS. (You
need to explicitly allow fused location from GMS and give it location
permissions with the latter but it did work.)

For anyone else wanting to test this:

1. Ensure that you cannot get a GPS fix by checking GPSTest or GNSSLogger
2. Ensure that you are able to get a fused location using GNSSLogger
3. Install and open the f-droid build built from this branch
4. Wipe app data and open
5. Give it accurate location permission
6. If it asks you to download not just the world map but also your current area
   via a checkbox above the download button, it works.

Signed-off-by: Atemu <git@atemu.net>
2024-11-27 15:22:10 +03:00
Viktor Govako
b2d3a5b1e0 [android] Removed Java 17 entry - doesn't work on MacOS with Java 21.
Signed-off-by: Viktor Govako <viktor.govako@gmail.com>
2024-11-19 00:25:26 -03:00
Alexander Borsuk
83d42a0f7e [android] Updated dependencies
Signed-off-by: Alexander Borsuk <me@alex.bio>
2024-11-13 10:11:19 +01:00
Alexander Borsuk
6b2bc7d7d3 [android] Update AGP to 8.7.2 and gradle to 8.9
Signed-off-by: Alexander Borsuk <me@alex.bio>
2024-11-13 10:11:19 +01:00
renderexpert
a7ae66fece Add tracing for Android
Signed-off-by: renderexpert <expert@renderconsulting.co.uk>
2024-11-05 06:59:56 -03:00
Viktor Govako
0c54729448 [android] New NDK, Gradle, CMake.
Signed-off-by: Viktor Govako <viktor.govako@gmail.com>
2024-09-28 11:52:36 +03:00
Alexander Borsuk
a910fcbcbd [android] Update dependencies
Signed-off-by: Alexander Borsuk <me@alex.bio>
2024-08-31 16:40:50 +02:00
Alexander Borsuk
6f18c0ea9f [android] Update gradle plugin to 8.5.2
Signed-off-by: Alexander Borsuk <me@alex.bio>
2024-08-31 16:40:50 +02:00
Alexander Borsuk
cbfc30a334 [android] Update NDK to the latest LTS version 27.0.12077973
Signed-off-by: Alexander Borsuk <me@alex.bio>
2024-08-31 16:40:50 +02:00
Alexander Borsuk
dea0664ee8 [android] Updated versions for dependencies
Signed-off-by: Alexander Borsuk <me@alex.bio>
2024-07-29 20:24:24 +02:00
Alexander Borsuk
f7a74de20e [android] Update Gradle to 8.5.0
Signed-off-by: Alexander Borsuk <me@alex.bio>
2024-07-29 20:24:24 +02:00
Alexander Borsuk
229c501bc9 [android] Update gradle plugun and androidx deps
Signed-off-by: Alexander Borsuk <me@alex.bio>
Signed-off-by: Roman Tsisyk <roman@tsisyk.com>
2024-05-25 19:19:52 +03:00
Andrew Shkrob
2fdf424ee6 [android-auto] Use compass and location data from car
Signed-off-by: Andrew Shkrob <andrew.shkrob.social@yandex.by>
2024-05-16 19:38:10 +03:00
Andrew Shkrob
14495ab274 [android-auto] Update to 1.7.0-alpha02
RoutePreview, PlaceListNavigation, Map templates are now deprecated.
Use MapWithContent template.

Remove PopToRootHack class as it is not needed.

Signed-off-by: Andrew Shkrob <andrew.shkrob.social@yandex.by>
2024-05-16 09:17:21 +03:00
Alexander Borsuk
6b5f800e04 [android] Updated NDK to 26.3.11579264
Signed-off-by: Alexander Borsuk <me@alex.bio>
2024-05-14 20:25:43 -03:00
Alexander Borsuk
998c248dbc [android] Updated libs
Signed-off-by: Alexander Borsuk <me@alex.bio>
2024-04-14 08:39:18 +02:00
Alexander Borsuk
ea640f756f [android] Update AGP to 8.3.2
Signed-off-by: Alexander Borsuk <me@alex.bio>
2024-04-14 08:39:18 +02:00
9520fd8ca5 [android] Update the Google Play release procedure
Before all new Google Play releases were published for phased 10% rollout
in the Production track. Now, a new Google Play release is initially
uploaded into "Closed Beta" track for 100% rollout and then promoted into
"Production" track after testing. The "Closed Beta" track (misleadingly
called "alpha" in the code) is invite-only and currently contains about
~1k users imported Firebase App Tester databases. Invited users can opt in
to install new pre-release versions for testing directly via Google Play.

Android releases are now initially tagged with `YYYY.MM.DD-x-android-rc`
(release-candidate) tags instead of `YYYY.MM.DD-x-android`. The production
`YYYY.MM.DD-x-android` tag is added after promotion in Google Play. This
kicks-off the F-Droid process as well. Huawei's version remains unpublished
until Android gets a green light in Google Play.

This change has two primary outcomes:

1. Users now can receive pre-production ("rc") via Google Play.
   This change uses invite-only "Closed Beta" track, but it can be
   changed to "Open Beta" track later.

2. Android versions in Google Play are now published after pre-production
   testing in a separate track in Google Play. Meanwhile, Google Play
   runs Monkey for free in such tracks and sends useful pre-prod reports.

There are no changes in Firebase App Tester - it works as usual. The primary
difference between App Tester and Google Play Open/Closed Beta is that
AppTester uses "app.organicmaps.beta" applicationId while Google Play uses
"app.organicmaps" id. This efficiently means that versions from App Testers
can be installed in parallel with Google Play, while Google Play's
Open/Closed version update the production app.

Please don't get confused with the word "beta" used in different places.
Google Play Open/Closed Beta actually will receive only pre-production
quality builds. App Tester probably can continue to be used both for
pre-production and ad-hoc experiemental version ("alpha"?).

Signed-off-by: Roman Tsisyk <roman@tsisyk.com>
2024-03-31 09:19:39 +03:00
f0656d8201 [android] Strip non-supported HTML tags from Huawei descriptions
Fixes #7221

Signed-off-by: Roman Tsisyk <roman@tsisyk.com>
2024-03-30 18:26:02 +02:00
Alexander Borsuk
5669f6cfe9 [android] Update AGP to 8.3.1
Signed-off-by: Alexander Borsuk <me@alex.bio>
2024-03-29 09:58:07 +01:00
renderexpert
7339f2503c Fix Vulkan diagnostics
Signed-off-by: renderexpert <expert@renderconsulting.co.uk>
2024-03-20 14:19:28 +01:00
Alexander Borsuk
9081f173bf
[android] Update Android Gradle Plugin to 8.3 (#7554)
Also, update some dependencies

Signed-off-by: Alexander Borsuk <me@alex.bio>
2024-03-10 08:51:28 +01:00
Alexander Borsuk
3c80ceeb9b [android] Upgrade NDK to r26c
Signed-off-by: Alexander Borsuk <me@alex.bio>
2024-03-10 09:49:11 +02:00
05a7e9c619 [android] Add 'androidx' dependency to build.gradle
Signed-off-by: Gonzalo Pesquero <gpesquero@yahoo.es>
2024-03-10 00:19:22 +02:00
Isira Seneviratne
ede7eda0c0
[android] Simplify some code using java.time using the code desugaring
Signed-off-by: Isira Seneviratne <isirasen96@gmail.com>
2024-03-06 12:39:57 +03:00
dea8699074 Revert "[android-auto] Use compass and location data from car"
This reverts commit 0e1b01c653.

Fixes #7416
See #6974
2024-02-18 13:39:30 +02:00
7e9b4a52b3 [android] Fix release flavor with applicationIdSuffix
Auto-generated `app_id` strings was always `app.organicmaps` in
all release builds no matter of the applicationIdSuffix value.

Fixes #7387

Signed-off-by: Roman Tsisyk <roman@tsisyk.com>
2024-02-15 10:11:26 +02:00
2f9ab5f8a6 [android] Change app names for debug and beta versions
Versions are almost indistinguishable in the launcher.

Signed-off-by: Roman Tsisyk <roman@tsisyk.com>
2024-02-12 15:36:13 +02:00
195163bbbd [android] Fix "No matching client found for package name"
Fixes #6689

Signed-off-by: Roman Tsisyk <roman@tsisyk.com>
2024-02-12 11:17:43 +02:00
47e6049e0d [android] Re-order android{} and dependencies{} in build.gradle
Gradle doesn't recognize flavor-specific dependencies when
dependencies{} section is before android{} section:

```
* What went wrong:
A problem occurred evaluating project ':app'.
> Could not find method webImplementation() for arguments
[com.google.android.gms:play-services-location:21.1.0] on object of type
org.gradle.api.internal.artifacts.dsl.dependencies.DefaultDependencyHandler.
```

No semantic changes.

Signed-off-by: Roman Tsisyk <roman@tsisyk.com>
2024-02-12 11:17:43 +02:00
566c9cdadd [android] Add .web suffix to Web version
Allow installation of Web version alongside of other versions.

Signed-off-by: Roman Tsisyk <roman@tsisyk.com>
2024-02-12 10:51:30 +02:00
Andrew Shkrob
0e1b01c653 [android-auto] Use compass and location data from car
Signed-off-by: Andrew Shkrob <andrew.shkrob.social@yandex.by>
2024-02-11 10:48:58 +02:00
Alexander Borsuk
8e9b32a4ec [android] Update AGP to 8.2.1
Also update a few other libraries

Signed-off-by: Alexander Borsuk <me@alex.bio>
2024-01-22 12:17:56 +02:00
04d610fd16 Remove UnusedResources lint rule
Signed-off-by: Jean-BaptisteC <jeanbaptiste.charron@outlook.fr>
2024-01-21 04:11:25 +02:00
1e6c69f69e [android] Fix buildconfig deprecation
Signed-off-by: Jean-BaptisteC <jeanbaptiste.charron@outlook.fr>
2024-01-07 20:34:34 +02:00
da919525a9 [android-auto] Remove compile-time feature flag for Android Auto
Android Auto has been accepted by Google. Google Play ignores
"enabled=false" in AndroidManifest.xml anyway.

This reverts commit 8d17e90b7d.

Signed-off-by: Roman Tsisyk <roman@tsisyk.com>
2023-12-14 08:38:41 +02:00
Alexander Borsuk
fc3302a011 [android] Minor dependencies update
Signed-off-by: Alexander Borsuk <me@alex.bio>
2023-12-12 23:29:31 +01:00
Alexander Borsuk
1a2f1440a5 [android] Update AGP to 8.2.0, gradle to 8.4
Signed-off-by: Alexander Borsuk <me@alex.bio>
2023-12-12 23:29:31 +01:00
Jean-Baptiste
d83b9e485e
[android] Use simple quotes in build.gradle
Signed-off-by: Jean-BaptisteC <jeanbaptiste.charron@outlook.fr>
2023-12-08 12:55:06 +03:00
8a74a414d2 [android] Fix deprecated androidx.preference.PreferenceManager
Signed-off-by: Roman Tsisyk <roman@tsisyk.com>
2023-12-03 17:53:37 +02:00
Alexander Borsuk
2397b676b6 Fixed dependencies when building with -DSKIP_TESTS or -DSKIP_TOOLS
Signed-off-by: Alexander Borsuk <me@alex.bio>
2023-11-28 14:11:29 +01:00
6482e1bae2 [android] Enable Java 17 language features
Almost all the new Java 12-17 **language** features can be used now:

- Text Blocks
  https://docs.oracle.com/en/java/javase/17/text-blocks/index.html

- Pattern Matching for switch Expressions and Statements
  https://docs.oracle.com/en/java/javase/17/language/pattern-matching-switch-expressions-and-statements.html

- Pattern Matching for instanceof
  https://docs.oracle.com/en/java/javase/17/language/pattern-matching-instanceof-operator.html

- Sealed Classes
  https://docs.oracle.com/en/java/javase/17/language/sealed-classes-and-interfaces.html

- Record Classes
  https://docs.oracle.com/en/java/javase/17/language/records.html
  This feature requires `java.lang.Record` class which is not available on
  old devices, but R8/D8 compiler in Android does so-called 'desugaring'.
  https://android-developers.googleblog.com/2023/06/records-in-android-studio-flamingo.html

More details on https://docs.oracle.com/en/java/javase/17/language/java-language-changes.html

Please note that Java 17 support doesn't extend to the new system classes
and APIs as they may not be available on old devices. The build toolchain
validates APIs based on the value minSdk setting, which is still API=21.
Certain APIs are available even on the old devices via R8/D8 'desugaring'.
See https://developer.android.com/build/jdks#compileSdk for details.

Signed-off-by: Roman Tsisyk <roman@tsisyk.com>
2023-11-26 09:58:51 +02:00
Alexander Borsuk
6c65e90080 [android] Upgrade agp to 8.1.4
Upgrade other dependencies too

Signed-off-by: Alexander Borsuk <me@alex.bio>
2023-11-25 15:50:29 +02:00