0

I'm using the Facebook sdk for android by adding in my gradle:

compile 'com.facebook.android:facebook-android-sdk:[4,5)'

Then I see a lot of errors like:

"Failed to resolve: X library"

So I ran a Gradle dependency report to see the full tree of dependencies and this is how I figured out that all these erros are because the Facebook SDK is calling another versions that do not match the current compileSdkVersion, buildToolsVersion and other libraries (25.3.1).

So I tried to simply update all my libraries to the v7:27.0.1 and explicity compile these libraries that the Facebook SDK is calling but there goes the main problem.

Issue 1 (Probably a simply bug of Android Studio): The Android Studio Link to install the required repository is not working so I manually downloaded it form the SDK Manager.

Main problem: With the build tools downloaded the gradle is still giving me these errors.

enter image description here

Any idea of how to solve this?

Brandon Zamudio
  • 2,853
  • 4
  • 18
  • 34

1 Answers1

1

Android support repository has been moved to new google maven repos. So what you need to do is add that repository to your list of repositorties.

repositories {
    google()
}

Or if you are on older version of gradle you should add sometinhg like this

repositories {
    maven( url "https://maven.google.com/ )
}
Blaz
  • 1,935
  • 15
  • 14