6

info JS server already running. info Installing the app...

Configure project :react-native-reanimated Native libs debug enabled: false Android gradle plugin: 7.2.1 Gradle: 7.5.1 building Reanimated2 WARNING:Software Components will not be created automatically for Maven publishing from Android Gradle Plugin 8.0. To opt-in to the future behavior, set the Gradle property android.disableAutomaticComponentCreation=true in the gradle.properties file or use the new publishing DSL.

Task :react-native-reanimated:downloadHermes UP-TO-DATE Download https:github.com/facebook/hermes/tarball/hermes-2022-09-14-RNv0.70.1-2a6b111ab289b55d7b78b5fdf105f466ba270fd7

Task :react-native-reanimated:downloadBoost UP-TO-DATE Download https:boostorg.jfrog.io/artifactory/main/release/1.76.0/source/boost_1_76_0.tar.gz

Task :react-native-reanimated:downloadDoubleConversion UP-TO-DATE Download https:github.com/google/double-conversion/archive/v1.1.6.tar.gz

Task :react-native-reanimated:downloadFolly UP-TO-DATE Download https:github.com/facebook/folly/archive/v2021.07.22.00.tar.gz

Task :react-native-reanimated:downloadGlog UP-TO-DATE Download https:github.com/google/glog/archive/v0.3.5.tar.gz

Task :react-native-reanimated:configureCMakeDebug[arm64-v8a] FAILED

Deprecated Gradle features were used in this build, making it incompatible with Gradle 8.0.

You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.

See https:docs.gradle.org/7.5.1/userguide/command_line_interface.html#sec:command_line_warnings 163 actionable tasks: 6 executed, 157 up-to-date

FAILURE: Build completed with 2 failures.

1: Task failed with an exception.

  • What went wrong: Execution failed for task ':react-native-reanimated:configureCMakeDebug[arm64-v8a]'.

[CXX1405] error when building with cmake using D:\c2c_mobile\node_modules\react-native-reanimated\android\CMakeLists.txt: Build command failed. Error while executing process C:\Users\User\AppData\Local\Android\Sdk\cmake\3.18.1\bin\cmake.exe with arguments {-HD:\c2c_mobile\node_modules\react-native-reanimated\android -DCMAKE_SYSTEM_NAME=Android -DCMAKE_EXPORT_COMPILE_COMMANDS=ON -DCMAKE_SYSTEM_VERSION=23 -DANDROID_PLATFORM=android-23 -DANDROID_ABI=arm64-v8a -DCMAKE_ANDROID_ARCH_ABI=arm64-v8a -DANDROID_NDK=C:\Users\User\AppData\Local\Android\Sdk\ndk\21.4.7075529 -DCMAKE_ANDROID_NDK=C:\Users\User\AppData\Local\Android\Sdk\ndk\21.4.7075529 -DCMAKE_TOOLCHAIN_FILE=C:\Users\User\AppData\Local\Android\Sdk\ndk\21.4.7075529\build\cmake\android.toolchain.cmake -DCMAKE_MAKE_PROGRAM=C:\Users\User\AppData\Local\Android\Sdk\cmake\3.18.1\bin\ninja.exe -DCMAKE_CXX_FLAGS=-fstack-protector-all -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=D:\c2c_mobile\node_modules\react-native-reanimated\android\build\intermediates\cxx\Debug\2w3pu2p1\obj\arm64-v8a -DCMAKE_RUNTIME_OUTPUT_DIRECTORY=D:\c2c_mobile\node_modules\react-native-reanimated\android\build\intermediates\cxx\Debug\2w3pu2p1\obj\arm64-v8a -DCMAKE_BUILD_TYPE=Debug -BD:\c2c_mobile\node_modules\react-native-reanimated\android.cxx\Debug\2w3pu2p1\arm64-v8a -GNinja -DANDROID_STL=c++_shared -DNATIVE_DEBUG=false -DREACT_NATIVE_TARGET_VERSION=70 -DANDROID_TOOLCHAIN=clang -DBOOST_VERSION=1_76_0 -DNODE_MODULES_DIR=D:\c2c_mobile\node_modules -DJS_RUNTIME=hermes -DJS_RUNTIME_DIR=D:\c2c_mobile\node_modules\react-native\sdks\hermes -DCLIENT_SIDE_BUILD=true -DIS_NEW_ARCHITECTURE_ENABLED=false -DPLAYGROUND_APP_NAME=D:\c2c_mobile\android\app -DRNVERSION=70}

  • Try:

Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights. ==============================================================================

2: Task failed with an exception.

  • What went wrong: java.lang.StackOverflowError (no error message)

  • Try:

Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights. ==============================================================================

BUILD FAILED in 23s

error Failed to install the app. Make sure you have the Android development environment set up: https:reactnative.dev/docs/environment-setup. Error: Command failed: gradlew.bat app:installDebug -PreactNativeDevServerPort=8081

FAILURE: Build completed with 2 failures.

1: Task failed with an exception.

  • What went wrong: Execution failed for task ':react-native-reanimated:configureCMakeDebug[arm64-v8a]'.

[CXX1405] error when building with cmake using D:\c2c_mobile\node_modules\react-native-reanimated\android\CMakeLists.txt: Build command failed. Error while executing process C:\Users\User\AppData\Local\Android\Sdk\cmake\3.18.1\bin\cmake.exe with arguments {-HD:\c2c_mobile\node_modules\react-native-reanimated\android -DCMAKE_SYSTEM_NAME=Android -DCMAKE_EXPORT_COMPILE_COMMANDS=ON -DCMAKE_SYSTEM_VERSION=23 -DANDROID_PLATFORM=android-23 -DANDROID_ABI=arm64-v8a -DCMAKE_ANDROID_ARCH_ABI=arm64-v8a -DANDROID_NDK=C:\Users\User\AppData\Local\Android\Sdk\ndk\21.4.7075529 -DCMAKE_ANDROID_NDK=C:\Users\User\AppData\Local\Android\Sdk\ndk\21.4.7075529 -DCMAKE_TOOLCHAIN_FILE=C:\Users\User\AppData\Local\Android\Sdk\ndk\21.4.7075529\build\cmake\android.toolchain.cmake -DCMAKE_MAKE_PROGRAM=C:\Users\User\AppData\Local\Android\Sdk\cmake\3.18.1\bin\ninja.exe -DCMAKE_CXX_FLAGS=-fstack-protector-all -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=D:\c2c_mobile\node_modules\react-native-reanimated\android\build\intermediates\cxx\Debug\2w3pu2p1\obj\arm64-v8a -DCMAKE_RUNTIME_OUTPUT_DIRECTORY=D:\c2c_mobile\node_modules\react-native-reanimated\android\build\intermediates\cxx\Debug\2w3pu2p1\obj\arm64-v8a -DCMAKE_BUILD_TYPE=Debug -BD:\c2c_mobile\node_modules\react-native-reanimated\android.cxx\Debug\2w3pu2p1\arm64-v8a -GNinja -DANDROID_STL=c++_shared -DNATIVE_DEBUG=false -DREACT_NATIVE_TARGET_VERSION=70 -DANDROID_TOOLCHAIN=clang -DBOOST_VERSION=1_76_0 -DNODE_MODULES_DIR=D:\c2c_mobile\node_modules -DJS_RUNTIME=hermes -DJS_RUNTIME_DIR=D:\c2c_mobile\node_modules\react-native\sdks\hermes -DCLIENT_SIDE_BUILD=true -DIS_NEW_ARCHITECTURE_ENABLED=false -DPLAYGROUND_APP_NAME=D:\c2c_mobile\android\app -DRNVERSION=70}

  • Try:

Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights. ==============================================================================

2: Task failed with an exception.

  • What went wrong: java.lang.StackOverflowError (no error message)

  • Try:

Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights. ==============================================================================

BUILD FAILED in 23s

at makeError (D:\c2c_mobile\node_modules\execa\index.js:174:9)
at D:\c2c_mobile\node_modules\execa\index.js:278:16
at processTicksAndRejections (internal/process/task_queues.js:95:5)
at async runOnAllDevices (D:\c2c_mobile\node_modules\@react-native-community\cli-platform-android\build\commands\runAndroid\runOnAllDevices.js:109:5)
at async Command.handleAction (D:\c2c_mobile\node_modules\react-native\node_modules\@react-native-community\cli\build\index.js:142:9)

info Run CLI with --verbose flag for more details.

13 Answers 13

9

The error is of reanimated library if you Downgrad your reanimated library to 2.9.1 the app will start crashing so use react-native-reanimated 2.17.0 for react-native version > 0.70

npm i [email protected]

Sign up to request clarification or add additional context in comments.

Comments

8

for those who uses m1 or m2 chip mac, the solution is installing rosetta.

softwareupdate --install-rosetta

Comments

3

If you are using m1 or m2 chip mac, the solution is to install Rosetta. Open a terminal and run

softwareupdate --install-rosetta

After doing that, do these steps:

  1. npm uninstall react-native-reanimated
  2. cd android && ./gradlew clean && cd ..
  3. npm react-native-reanimated
  4. cd android && ./gradlew clean && cd ..
  5. run project

That should do the trick

1 Comment

the steps work. thanks.
2

I fixed the above issue. please try reinstall reanimated version.

1.npm uninstall react-native-reanimated 2.npm install [email protected]

it's 100% working for me.

Comments

2

This worked for me (Windows 10, react-native 0.72.5, react-native-reanimated 3.5.4)

cd android
./gradlew clean
cd ..
npm start -- --reset-cache

Comments

1

This worked for me (Windows 11, react-native: "0.72.5", react-native-reanimated: "^3.5.4")

  1. Run cd android in project directory
  2. Open command prompt and run gradlew clean
  3. Run cd .., then run npx react-native run-android

1 Comment

To add to this answer, what worked in my case was running gradlew installDebug from the android folder instead of running npx react-native run-android from the root.
0

I had a similar issue, what worked for me was to delete the NDK folder, for you, I can see that it's located here C:\Users\User\AppData\Local\Android\Sdk\ndk\. Delete it, then do ./gradlew clean and run react-native run-android.

2 Comments

Your answer could be improved with additional supporting information. Please edit to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers in the help center.
Remember for Windows go to the android folder of the project and run gradlew Clean (Without ./). Then back to folder root run npx react-native run-android
0

For those who are on windows, make sure that you have JAVA SDK installed and JAVA_HOME variable is added in Environment Variables....

Comments

0

This error occurred me right after my computer power offed(Bad electricity). What I've done was to solve this issue that I deleted my node_modules in my Project and executed the install command.

npm install

And then after run my project with

npm run android

Command, It worked.

Comments

0

I have the same issues (I was using node v18, react native 0.73 and windows 11).

1/ remove node_modules (rm -rf node_modules if you are using git bash)
2/ change to node v20 (nvm list -> nvm use 20.X.X (with me is 20.3.1))
3/ re-install node_modules (npm i or yarn)
4/ cd android -> ./gradlew clean
5/ yarn dev or npm run dev

Comments

0

i solved it by these steps :
First go to android studio and check your cmake version and make sure you have latest version of cmake if not install it
then go to your project and fo to android folder and make local.properties file on it.
in local.properties give cmake directory on it in my case i install 4.0.2 version so i put this

cmake.dir=C:\\Users\\DELL\\AppData\\Local\\Android\\Sdk\\cmake\\4.0.2

and then clean build folder
cd android
gradlew clean
cd ..
npx react-native run-android

If you face again this issue so you have to download these two softwares on your pc ont in a project on our system
**1) VC_redist.x86
2) VC_redist.x64

Download these two from google and run it then you can get rid of this error 100% Working**

Comments

-2

I can find out the solution. you can below line in your babel.config.js file

plugins: ['react-native-reanimated/plugin'],

and Please refer this site https://docs.swmansion.com/react-native-reanimated/docs/fundamentals/installation/

1 Comment

As it’s currently written, your answer is unclear. Please edit to add additional details that will help others understand how this addresses the question asked. You can find more information on how to write good answers in the help center.
-2

Resolved by following steps

  1. Remove build and .cxx folder in the android/app/ directory.
  2. Run the command in terminal cd android && ./gradlew clean
  3. Open gradle.properties files
  4. newArchEnabled=false
  5. Run the project cd .. && npm start -- --reset-cache
  6. Run the command npm run android

1 Comment

Some devices need to use newArchEnabled...

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.