admin管理员组文章数量:1389754
When I try to make android build using these mands yarn run android
OR react-native run-android
then I have shown this error. Please help mw solve this error.
here's package.json
"@react-native-firebase/admob": "^11.5.0",
"@react-native-firebase/app": "^11.5.0",
"@react-native-firebase/messaging": "^11.5.0",
error:
> Configure project :react-native-firebase_messaging
:react-native-firebase_messaging package.json found at /Users/apple/Desktop/xnd-react-native/node_modules/@react-native-firebase/messaging/package.json
:@react-native-firebase_app package.json found at /Users/apple/Desktop/xnd-react-native/node_modules/@react-native-firebase/app/package.json
:react-native-firebase_messaging:firebase.bom using default value: 26.8.0
:react-native-firebase_messaging package.json found at /Users/apple/Desktop/xnd-react-native/node_modules/@react-native-firebase/messaging/package.json
:react-native-firebase_messaging:version set from package.json: 11.5.0 (11,5,0 - 11005000)
:react-native-firebase_messaging:androidpileSdk using custom value: 31
:react-native-firebase_messaging:android.targetSdk using custom value: 31
:react-native-firebase_messaging:android.minSdk using custom value: 21
:react-native-firebase_messaging:reactNativeAndroidDir /Users/apple/Desktop/xnd-react-native/node_modules/react-native/android
> Task :@react-native-firebase_messaging:pileDebugJavaWithJavac FAILED
Deprecated Gradle features were used in this build, making it inpatible with Gradle 7.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See .5/userguide/mand_line_interface.html#sec:mand_line_warnings
17 actionable tasks: 1 executed, 16 up-to-date
When I try to make android build using these mands yarn run android
OR react-native run-android
then I have shown this error. Please help mw solve this error.
here's package.json
"@react-native-firebase/admob": "^11.5.0",
"@react-native-firebase/app": "^11.5.0",
"@react-native-firebase/messaging": "^11.5.0",
error:
> Configure project :react-native-firebase_messaging
:react-native-firebase_messaging package.json found at /Users/apple/Desktop/xnd-react-native/node_modules/@react-native-firebase/messaging/package.json
:@react-native-firebase_app package.json found at /Users/apple/Desktop/xnd-react-native/node_modules/@react-native-firebase/app/package.json
:react-native-firebase_messaging:firebase.bom using default value: 26.8.0
:react-native-firebase_messaging package.json found at /Users/apple/Desktop/xnd-react-native/node_modules/@react-native-firebase/messaging/package.json
:react-native-firebase_messaging:version set from package.json: 11.5.0 (11,5,0 - 11005000)
:react-native-firebase_messaging:android.pileSdk using custom value: 31
:react-native-firebase_messaging:android.targetSdk using custom value: 31
:react-native-firebase_messaging:android.minSdk using custom value: 21
:react-native-firebase_messaging:reactNativeAndroidDir /Users/apple/Desktop/xnd-react-native/node_modules/react-native/android
> Task :@react-native-firebase_messaging:pileDebugJavaWithJavac FAILED
Deprecated Gradle features were used in this build, making it inpatible with Gradle 7.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle/6.5/userguide/mand_line_interface.html#sec:mand_line_warnings
17 actionable tasks: 1 executed, 16 up-to-date
Share
Improve this question
asked Nov 6, 2021 at 6:51
vjtechnovjtechno
4842 gold badges7 silver badges22 bronze badges
3
- I am also facing the same issue since last month....has anybody found any solution to this?? – Sjonchhe Commented Nov 11, 2021 at 17:02
- @Sjonchhe I have found the solution. you just update the jdk version and try it(remend jdk 11) – vjtechno Commented Nov 12, 2021 at 6:45
- @vjtechno Can you tell how you updated the jdk version? Thanks – A Osman Commented Nov 13, 2021 at 1:50
3 Answers
Reset to default 4I also have the same issue in jdk 8. When I change the jdk 8 to 11, it work for me.
To update from jdk 8 to 11 check https://github./invertase/react-native-firebase/issues/1988#issuement-1070831039
Update the JDK version and try it,
you can update JDK using this mand
choco install -y nodejs-lts openjdk11
When I switched from JDK 8 to 11, it solved it.
Following the instruction to switch
Open a new Terminal window and input:
/usr/libexec/java_home -V
It might look like this:
Matching Java Virtual Machines (2): 11.0.17 (arm64) "Oracle Corporation" - "Java SE 11.0.17" /Library/Java/JavaVirtualMachines/jdk- 11.0.17.jdk/Contents/Home 1.8.0_292 (x86_64) "AdoptOpenJDK" - "AdoptOpenJDK 8" /Library/Java/JavaVirtualMachines/adoptopenjdk- 8.jdk/Contents/Home /Library/Java/JavaVirtualMachines/jdk- 11.0.17.jdk/Contents/Home
You might see only one which might be 1.8(JDK 8), if so then go to https://www.oracle./java/technologies/downloads/ to download JDK 11.
After a successful download and installation. you will run this mand to switch.
export JAVA_HOME=`/usr/libexec/java_home -v 1.8`
Check your JDK version in a Terminal:
java --version
You can also check out this link below
https://medium./@devkosal/switching-java-jdk-versions-on-macos-80bc868e686a
本文标签: javascriptgt Task reactnativefirebasemessagingcompileDebugJavaWithJavac FAILEDStack Overflow
版权声明:本文标题:javascript - > Task :@react-native-firebase_messaging:compileDebugJavaWithJavac FAILED - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1744677823a2619219.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论