简体   繁体   中英

Android resource linking failed at google_play_service_version in generated menifest

When I set minifyEnabled true and build aar. its giving error 'android resource linking failed' at google_play_services_version in manifest while integrating it to the project.

I have added below code to my aar manifest.

<meta-data
android:name="com.google.android.gms.version"
android:value="@integer/google_play_services_version" />

and in proguard-rules.pro i have added

-keepnames class com.google.android.gms.** {*;}

And if i set minifyEnabled false than all works proper.

Can anyone help me out i am stuck.

You are setting the minifyEnabled true then defined the progurad rules for all third parties and other. Update each rule.

I solve this issue by keeping google_play_services_version values.xml file inside our main project.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM