1

I have an android studio based project.To reduce the resource I have used the

android {
buildTypes {
    release {
        shrinkResources true
        minifyEnabled true
        proguardFiles getDefaultProguardFile('proguard-android.txt'),
                'proguard-rules.pro'
      }
    }
  }

It's working properly, The unused resources are removed from the built apk.

Now I want to build the same project using Android.mk file from the AOSP build.

Is it possible to use minifyenabled = true and other options in Android.MK or any replacement for that?

Any help will be appreciated.

Midhun PM
  • 512
  • 1
  • 7
  • 24
  • You need to use `shrinkResources = true` too! minifyenabled will shortcut names methods and classes and mark unused resources, then shrinkResources actually removes that marked unused resources. – MohammadL May 22 '18 at 04:54
  • 1
    Thanks for the answer. I did the same in my build.gradle file. and it works properly. I want to know is it possible to use in Android.mk file? – Midhun PM May 22 '18 at 04:55
  • the question updated @MohammadL do you have any idea regarding this, please help me – Midhun PM May 22 '18 at 05:10
  • sorry I don't work with Android.mk yet – MohammadL May 22 '18 at 22:54
  • @MidhunPM Any solution for this question? I would like to do the same thing! – lucky1928 Feb 22 '22 at 16:20

0 Answers0