-4

If My APK consist of 'armeabi-v7a' 'arm64-v8a' 'x86' 'x86_64' folders in lib, But inside that folders, is It means it supports both 64-bit and 32-bit.

Because already APk built consist of 'armeabi-v7a' 'arm64-v8a' 'x86' 'x86_64' folders in lib. But 'armeabi-v7a' and 'x86' folder consist of some *.so file which is not there in 'arm64-v8a' and 'x86_64'

Now is it necessary to add - ndk { abiFilters 'armeabi-v7a', 'arm64-v8a', 'x86' ,'x86_64' }

Sony
  • 1
  • 1
  • 1

1 Answers1

4

To convert 32bit to 64bit just add the following code in your gradle file like this.

android {
   compileSdkVersion 27
   defaultConfig {
       appId "com.google.example.64bit"
       minSdkVersion 15
       targetSdkVersion 28
       versionCode 1
       versionName "1.0"
      ***ndk.abiFilters 'armeabi-v7a','arm64-v8a','x86','x86_64' //add this line***
}

if you want to see the apk is 32bit or 64 bit just follow these steps:

Open Android Studio, and open any project. From the menu, select Build > Analyze APK. Choose the APK you wish to evaluate.

Look within the lib folder, which is where you will find any '.so' files. If you can not find any '.so' files in your app at all, then your app is already ready and no further action is required. If you see armeabi-v7a or x86, then you have 32-bit libraries.

Check to see if you have similar '.so' files in the arm64-v8a or x86_64 folder. If you do not have any arm64-v8a or x86_64 libraries, you'll need to update your build process to start building and packaging those artifacts in your APK.

If you already see both libraries being packaged, you can skip ahead to Test Your app on a 64-bit device.

Maelig
  • 2,046
  • 4
  • 24
  • 49
  • Developer console reject app to upload... not worthy – Vasudev Vyas Aug 07 '19 at 09:10
  • if you are using compileSdkVersion less then 28 or using any native library and not added this line "ndk.abiFilters 'armeabi-v7a','arm64-v8a','x86','x86_64' //add this line" in your gradle, google will must reject your app. So you need to use latest compileSdkVersion as 29. – Muhammad Usman Nov 21 '19 at 04:52
  • Thanks Muhammad but i change my library and it was completed.. thanks for the response – Vasudev Vyas Nov 21 '19 at 04:56