I setup dev environment for my new m1 laptop and faced with weird error when tryied to build React Native 0.72.x New Architecture on Android:
[CXX1428] exception while building Json
A problem occurred starting process
'command /Users/my/Library/Android/sdk/cmake/3.22.1/bin/cmake'
-
I was managed to fix it removing all cache:
rm -rf android/app/build/ android/app/.cxx/ ./android/gradlew clean -p android and reinstalling some Android SDK components:
2.1 open Android Studio -> open Settings -> then Appearance & Behavior -> System Settings -> Android SDK ->choose SDK Tools -> enable Show Package Details
2.2 And then unmark all CMake, NDK, Command build tools versions:
2.3 then Apply
2.4 finally install again:
-
latestCommand-line Tools -
3.22.1CMake -
23.1.7779620NDK

Top comments (1)
rm -rf android/app/build/ android/app/.cxx/
./android/gradlew clean -p android
This even worked for react-native": "0.76.2