Using microG EN as library
See original GitHub issueI am attempting to use microG as a library for the SwissCovid app as has been suggested by @mar-v-in.
My apologies in advance if I am doing something silly, just starting up with microG…
What I have done so far is remove the dependencies on GMS in my project, put the relevant modules in (play-services-core
etc.), implement provideDiagnosisKeys()
in the client lib, and minor fixes until the app compiles. Now the app starts running, but as soon as it tries to start EN (sending com.google.android.gms.nearby.exposurenotification.START
Intent), it fails to bind in MultiConnectionKeeper.this.context.bindService()
(returns false
), eventually returning API_UNAVAILABLE
to the app. I have tried to change GMS_PACKAGE_NAME to org.microg.gms
or the app package, with no success.
From logcat:
2020-09-17 15:14:18.645 4340-5972/? W/ActivityManager: Unable to start service Intent { act=com.google.android.gms.nearby.exposurenotification.START pkg=org.microg.gms } U=0: not found
My questions are:
- Any hints on what I should be changing to make it work?
- Can the app as such even run on a phone with Google GMS installed (which is what I am testing on right now)? Should I rename all com.google.android.gms to avoid conflicts?
- Am I missing something to enable microG, some sort of init()?
Thank you in advance for any help!
Issue Analytics
- State:
- Created 3 years ago
- Reactions:3
- Comments:19 (16 by maintainers)
A version of SwissCovid using microG as a library is now available on F-Droid. Thank you @Bubu and @fynngodau for your help!
@cgrigis
https://codeberg.org/corona-contact-tracing-germany/cwa-android/src/branch/main/fdroidrepo/metadata/de.corona.tracing.yml + https://codeberg.org/corona-contact-tracing-germany/cwa-android/src/branch/main/metadata
feel free to ask any questions that come up.