问题
I need to make a customized Proguard configuration. However I cannot find out how to do that. When building a new configuration file is copied into the /obj/release/proguard folder. How can this configuration file be customized?
回答1:
- Just put your
Proguard.cfginto your Project - Right click on
Proguard.cfg> "Build Action" > "ProguardConfiguration"
回答2:
The above answer is 100% correct on how to add the file. To make sure you file gets picked up you can check the output logs, it will contain something like this:
ProguardConfigurationFiles:
{sdk.dir}tools\proguard\proguard-android.txt;
{intermediate.common.xamarin};
{intermediate.references};
{intermediate.application};
Proguard.cfg;
NOTE: Make sure that you set your MSBuild output verbosity to Detailed for this (Tools > Options > Build and Run)
来源:https://stackoverflow.com/questions/34380223/xamarin-visual-studio-2015-custom-proguard-configuration