Trusted answers to developer questions

What is the Android resource linking failed error?

Get Started With Machine Learning

Learn the fundamentals of Machine Learning with this free course. Future-proof your career by adding ML skills to your toolkit — or prepare to land a job in AI or Data Science.

While developing an Android application in Android Studio, you may come across some errors. One such error is the Android resource linking failed error.

The error might look something like this:

    Error:FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:processDebugResources'.
> Android resource linking failed (AAPT2 27.0.3 Daemon #0)

How to fix the error

Openplatforms/android/app/build.gradleandplatforms/android/build.gradle and replace the following code in the files:

'com.android.support:support-v4:+'

With:

'com.android.support:support-v4:27.1.0'

This should yield the following configuration settings:

configurations.all {
resolutionStrategy {
    force 'com.android.support:support-v4:27.1.0'
}}

The Android resource linking failed error can also occur if you have an error in any of your XML resources.

RELATED TAGS

general

CONTRIBUTOR

Sarvech Qadir
Copyright ©2024 Educative, Inc. All rights reserved
Did you find this helpful?