react-native-safe-area-context
react-native-safe-area-context copied to clipboard
Android build is failing on RN version 0.69.3
I am updating my current application to RN version 0.69.3 so as to reap the benefits of Hermes and TurboModules. I use React Navigation which is dependent on this library.
To make sure that no other library or configuration is causing the issue, I spun out a new project, enabled Hermes, compiles fine. Added this dependency on this project and build never succeeds.
The exact gradle task where build fails is :react-native-safe-area-context:configureNdkBuildDebug[armeabi-v7a]
Here is the whole stack trace:
What went wrong: Execution failed for task ':react-native-safe-area-context:configureNdkBuildDebug[armeabi-v7a]'. [CXX1405] error when building with ndkBuild using /Users/deepak.ramrakhyani/Projects/RNTurboModules/node_modules/react-native-safe-area-context/android/src/main/jni/Android.mk: Build command failed. Error while executing process /Users/deepak.ramrakhyani/Library/Android/sdk/ndk/21.4.7075529/ndk-build with arguments {NDK_PROJECT_PATH=null APP_BUILD_SCRIPT=/Users/deepak.ramrakhyani/Projects/RNTurboModules/node_modules/react-native-safe-area-context/android/src/main/jni/Android.mk APP_ABI=armeabi-v7a NDK_ALL_ABIS=armeabi-v7a NDK_DEBUG=1 NDK_OUT=/Users/deepak.ramrakhyani/Projects/RNTurboModules/node_modules/react-native-safe-area-context/android/build/intermediates/cxx/Debug/6l6st2g3/obj NDK_LIBS_OUT=/Users/deepak.ramrakhyani/Projects/RNTurboModules/node_modules/react-native-safe-area-context/android/build/intermediates/cxx/Debug/6l6st2g3/lib APP_CFLAGS+=-Wall APP_CFLAGS+=-Werror APP_CFLAGS+=-fexceptions APP_CFLAGS+=-frtti APP_CFLAGS+=-DWITH_INSPECTOR=1 APP_CPPFLAGS+=-std=c++17 APP_PLATFORM=android-21 APP_STL=c++_shared NDK_TOOLCHAIN_VERSION=clang GENERATED_SRC_DIR=/Users/deepak.ramrakhyani/Projects/RNTurboModules/android/app/build/generated/source PROJECT_BUILD_DIR=/Users/deepak.ramrakhyani/Projects/RNTurboModules/android/app/build REACT_ANDROID_DIR=/Users/deepak.ramrakhyani/Projects/RNTurboModules/node_modules/react-native/ReactAndroid REACT_ANDROID_BUILD_DIR=/Users/deepak.ramrakhyani/Projects/RNTurboModules/node_modules/react-native/ReactAndroid/build APP_SHORT_COMMANDS=false LOCAL_SHORT_COMMANDS=false -B -n} Android NDK: ERROR:/Users/deepak.ramrakhyani/Projects/RNTurboModules/node_modules/react-native-safe-area-context/android/src/main/jni/Android.mk:fb: LOCAL_SRC_FILES points to a missing file
Android NDK: Check that /Users/deepak.ramrakhyani/Projects/RNTurboModules/android/app/build/react-ndk/exported/armeabi-v7a/libfb.so exists or that its path is correct
What's weird is, I am not even triggering a build for [armeabi-v7a]. In my gradle.properties file, I have modified the value of reactNativeArchitectures to arm64-v8a. But still a NdK build of [armeabi-v7a] is running and it can't find the following path:
/Users/deepak.ramrakhyani/Projects/RNTurboModules/android/app/build/react-ndk/exported/armeabi-v7a/libfb.so
Removing the dependency on this library makes the project compile successfully. However, I do use SafeAreaView in my main project.
+1
https://github.com/th3rdwave/react-native-safe-area-context/pull/348