Missmatching versions of android support lib
See original GitHub issueAfter Ive done yarn add react-native-fast-image
and react-native link react-native-fast-image
I get this error when trying to run my app. It seems like react-native-fast-image
uses support-v4/27.1.1
but react-native has another version installed. How can I resolve this?
C:\Utveckling\myapp>react-native run-android
Scanning folders for symlinks in C:\Utveckling\myapp\node_modules (32ms)
JS server already running.
Building and installing the app on the device (cd android && gradlew.bat installDebug)...
File C:\Users\myapp\.android\repositories.cfg could not be loaded.
FAILURE: Build failed with an exception.
* What went wrong:
A problem occurred configuring project ':app'.
> Could not resolve all dependencies for configuration ':app:_debugApkCopy'.
> Could not find com.android.support:support-v4:27.1.1.
Searched in the following locations:
file:/C:/Users/myapp/AppData/Local/Android/sdk/extras/android/m2repository/com/android/support/support-v4/27.1.1/support-v4-27.1.1.pom
file:/C:/Users/myapp/AppData/Local/Android/sdk/extras/android/m2repository/com/android/support/support-v4/27.1.1/support-v4-27.1.1.jar
file:/C:/Utveckling/myapp/android/sdk-manager/com/android/support/support-v4/27.1.1/support-v4-27.1.1.jar
Required by:
elkedjan:app:unspecified > com.android.support:appcompat-v7:23.0.1
> Could not find com.android.support:support-v4:27.1.1.
Searched in the following locations:
file:/C:/Users/myapp/AppData/Local/Android/sdk/extras/android/m2repository/com/android/support/support-v4/27.1.1/support-v4-27.1.1.pom
file:/C:/Users/myapp/AppData/Local/Android/sdk/extras/android/m2repository/com/android/support/support-v4/27.1.1/support-v4-27.1.1.jar
file:/C:/Utveckling/myapp/android/sdk-manager/com/android/support/support-v4/27.1.1/support-v4-27.1.1.jar
Required by:
myapp:app:unspecified > myapp:react-native-fast-image:unspecified
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
BUILD FAILED
Total time: 11.446 secs
Could not install the app on the device, read the error above for details.
Make sure you have an Android emulator running or a device connected and have
set up your Android development environment:
https://facebook.github.io/react-native/docs/getting-started.html
Issue Analytics
- State:
- Created 5 years ago
- Reactions:5
- Comments:9 (1 by maintainers)
Top Results From Across the Web
Android Studio, mismatch support library versions error, but ...
Project in Android Studio, and getting this error: com.android.support libraries must use the exact same version specification.
Read more >Recent Support Library Revisions - Android Developers
This page provides details about the most recent Support Library package releases. For earlier releases, see the Support Library Revisions Archive.
Read more >Support Library - Android Developers
Support Library Release Versions ... The release version of the Support Library, such as 24.2.0 or 25.0.1, is different from the minimum API...
Read more >Support Library Packages - Android Developers
The Android Support Library contains several library packages that can be included in your application. Each of these libraries supports a specific range...
Read more >Support Library Setup - Android Developers
Note: With the release of Android 9.0 (API level 28) there is a new version of the support library called AndroidX which is...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
If you’re using a recent version of React Native then you can configure the support lib version at the project level in
build.gradle
:In the most recent version of React Native Fast Image (5.0.10) this property is used.
try add the code in android/build.gradle: