Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What google services are banned in Harmony OS (here is a list that I have used in my android app.)

I need to upload my android apk file in harmony os and as google services are banned in this platform, I would have to use the alternative platform. Here is a list of google services that I have used. Please help me to distinguish what google services would I need to override and recode for Harmony OS.

com.google.android.material
com.google.firebase
com.google.android.gms:play-services-auth
com.google.android.gms:play-services-maps
com.google.android.gms:play-services-location
com.google.android.libraries.places
com.google.code.gson
com.google.protobuf.nano:protobuf-javanano
like image 758
viper Avatar asked Aug 10 '20 07:08

viper


People also ask

Will Huawei get Google back in 2022?

Company plans to press ahead with its five-year globalisation strategy and said it will not back away from expansion. China's Huawei Technologies will continue to use its own operating system amid its inability to access Google's services and will use it to pursue an aggressive expansion strategy.

Can I use Google on Huawei?

Can I use Google Search on the Huawei Browser? You can use HUAWEI Browser to open the home page of Google Search for searching.

Is Huawei still banned from Google?

No, the Huawei ban only affects products released after May 15, 2019. The Huawei P30 Pro launched on March 26, 2019, which means it can still feature Google apps.

How many apps use harmony?

Huawei's HarmonyOS already has 134,000 apps, over 4 million developers have signed on. Eligible devices that migrate to HarmonyOS 2.0 will retain apps and data (the exception being apps that rely on Google Play Services).


2 Answers

  1. Your app has integrated GMS. As new Huawei phones are banned from using GMS, you app, if with GMS integrated, will be unable to run on new Huawei phones. If you want your app to run on these phones, integrate Huawei Mobile Services (HMS).

If you want to use the map service in your app, and also want your app to run on both Huawei phones and Google Android phones, you can integrate both GMS Map Kit and HMS Map Kit. Then your app will use HMS Map Kit on Huawei phones, while using GMS Map Kit on Google Android phones.

In the list you provided, you use these GMS services:

com.google.firebase
com.google.android.gms:play-services-auth
com.google.android.gms:play-services-maps
com.google.android.gms:play-services-location
com.google.android.libraries.places

You can refer to the following Huawei mobile services:

Account Kit, Map Kit, Location Kit, Site Kit, AppGallery Connect auth service

  1. You can use this IDE plug-in called HMS Core Toolkit to help you analyze where GMS is used in your code. HMS Core Toolkit supports analysis of manual conversion, aiming to increase the conversion efficiency. It provides two conversion policies: Add HMS API and To HMS API. You can choose one as required.
  • Choose HMS > Convertor > New Conversion to start scanning, analysis, and conversion.

The Convertor is a code conversion tool supporting Java and Kotlin projects. This tool can help you quickly convert the existing Android app code for calling third-party APIs into the app code integrated with the HMS Core.

New Conversion can automatically convert the GMS APIs called by apps into HMS APIs, using either the To HMS API or Add HMS API conversion policy.

  1. Upload your app through AppGallery Connect.
  • How to How to create and release your app on HUAWEI Developer?
  1. Register and create your app: Register and sign in to your HUAWEI Developer account, go to AppGallery Connect, create a new app, and upload the APK.
  2. Set basic information: Set languages and basic app information, such as app name, introduction, screenshots, and app category.
  3. Set release information: Select your business model (free or premium), release countries and regions, and a link to the privacy statement.
  4. Submit for release: Confirm that all of the information provided is correct, and submit your app for review.
like image 124
shirley Avatar answered Sep 29 '22 01:09

shirley


Huawei phones are Android, not Harmony OS. However Huawei wearables are running on Harmony OS, which is not compatible with Android, so your APK will not work in this case. You will need to rewrite your app from scratch for Harmony OS.

From the list your provided, these use Google Mobile Services:

  • com.google.firebase
  • com.google.android.gms:play-services-auth
  • com.google.android.gms:play-services-maps
  • com.google.android.gms:play-services-location
  • com.google.android.libraries.places

You have alternatives for each one through HMS Core. There are some wrapper libraries made by third parties, for example for maps and location, that make this migration easier.

like image 27
m0skit0 Avatar answered Sep 29 '22 03:09

m0skit0