 <p>You can see there are comments in aapt_rules.txt. Beside each kept class there are corresponding layout files that referenced this class. Like that:</p> <pre><code># view res/layout/abc_list_menu_item_layout.xml #generated:17 # view res/layout/abc_popup_menu_item_layout.xml #generated:17 -keep class android.support.v7.internal.view.menu.ListMenuItemView { &lt;init&gt;(...); } </code></pre> <p>If you remove the layout file from build process this line will desappear and class will not be kept. The class will be shrinked if it's not actually used somewhere.</p> <p>So how can we remove layout file from appcompat library? I can see few options, none of them is perfect but they work. </p> <ol> <li><p>You can just remove file from sdk\extras\android\m2repository\com\android\support\appcompat-v7\version\appcompat-v7-version.aar. Enough for testing, bad for production because the same file may be used in some other projects. I tried and it works.</p></li> <li><p>Put fake file with the same name into your project. Name conflict will happen. Build process will prefer your fake file because project files have higher priority. This way file from appcompat will be ignored. I tried and it works.</p></li> <li><p>Probably you can make some fancy gradle script that removes unwanted files during the build process. I haven't tried that.</p></li> </ol> <p>(shrinkResources option doesn't help because aapt_rules.txt is generated BEFORE shrinkResources is actually involved.)</p> <p>I hope somebody will suggest a better way to do that</p> <p>After doing that all unwanted lines were gone from aapt_rules.txt. But it saved me about 100 KB from the final apk size. So not big deal for me. But in your case results may be different.</p>