From b3a21ac9e3621ebb1be3230a1959ce29bd8e8d9a Mon Sep 17 00:00:00 2001 From: CCXXXI Date: Mon, 30 Jan 2023 23:49:42 +0800 Subject: [PATCH] build: fix linker error ld: error: found local symbol '__bss_end__' in global part of symbol table in file C:/Users/ccxxxi/projects/ecg_monitor/build/app/pytorch_android-1.10.0.aar/jni/arm64-v8a\libpytorch_jni.so https://github.com/android/ndk/issues/927#issuecomment-803448944 https://stackoverflow.com/questions/57175936/how-to-set-local-ldflags-local-cppflags-with-cmake-in-ndk --- android/app/CMakeLists.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/android/app/CMakeLists.txt b/android/app/CMakeLists.txt index f81b5073..5d33525c 100644 --- a/android/app/CMakeLists.txt +++ b/android/app/CMakeLists.txt @@ -19,3 +19,4 @@ find_library(FBJNI_LIBRARY fbjni PATHS ${PYTORCH_LINK_DIRS} NO_CMAKE_FIND_ROOT_PATH) target_link_libraries(ecg_model ${PYTORCH_LIBRARY} ${FBJNI_LIBRARY}) +target_link_options(ecg_model PUBLIC "-Wl,--no-fatal-warnings")