[react-native-fbsdk] Build failed with Error :app:processDebugResources and values-v26.xml resource not found
See original GitHub issueWorking on React Native Facebook login with ‘react-native-fbsdk’ I am getting my build fail.
Environment
Environment: OS: Windows 7 Node: 8.9.3 Yarn: 1.5.1 npm: 4.6.1 Watchman: Not Found Xcode: N/A Android Studio: Not Found Packages: (wanted => installed) react: 16.3.0-alpha.1 => 16.3.0-alpha.1 react-native: 0.54.0 => 0.54.0
Expected Behavior
Build To get successful without errors
Actual Behavior
Following Error:
C:\Users\HP\Desktop\collegesearch\android\app\build\intermediates\res\merged\de ug\values-v26\values-v26.xml:15:21-54: AAPT: No resource found that matches the given name: attr ‘android:keyboardNavigationCluster’.
C:\Users\HP\Desktop\collegesearch\android\app\build\intermediates\res\merged\de ug\values-v24\values-v24.xml:3: error: Error retrieving parent for item: No res urce found that matches the given name ‘android:TextAppearance.Material.Widget. utton.Borderless.Colored’.
:app:processDebugResources FAILED
FAILURE: Build failed with an exception.
- What went wrong: Execution failed for task ‘:app:processDebugResources’.
com.android.ide.common.process.ProcessException: Failed to execute aapt
Steps to Reproduce
Make a new React Native app with Native Code(Not CRNA) using following command:
react-native init YourProjectName
get to the project directory:
CD YourProjectName
Now for installing react-native-fbsdk(For implementing Login functionality via Facebook):
npm install react-native-fbsdk
Link the module:
react-native link react-native-fbsdk
Follow the guide in the following link: https://github.com/facebook/react-native-fbsdk (Make changes in MainActivity.java, MainApplication.java, Stings.xml and AndroidManifest.xml, build.gradle files as you follow the above guide.)
I advice to do the gradlew clean by:
CD android
gradlew clean
Make sure you have an emulator running.
Then you build the code using following command: react-native run-android
Issue Analytics
- State:
- Created 6 years ago
- Reactions:2
- Comments:7
This seems to be an issue that has been going around for a few months. I managed to get it working by downgrading react-native-fbsdk to v0.6.3 and facebook-android-sdk to v4.22.1.
Workaround
yarn add react-native-fbsdk@0.6.3
android/app/build.gradle
fileRelated threads
@hramos You tagged this issue as “Incomplete Reproduction Steps”. Can I help with clarifying any missing steps, or would having a repo to fork help with this? I’m experiencing the same problem on macOS Sierra too.