[android][readme] Aar native linking add fbjni (#40578)
Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/40578
Test Plan: Imported from OSS
Differential Revision: D22239286
Pulled By: IvanKobzarev
fbshipit-source-id: 7a4160b621af8cfcc3b3d9e6da1a75c8afefba27
diff --git a/android/README.md b/android/README.md
index 4914aa8..bf5fa02 100644
--- a/android/README.md
+++ b/android/README.md
@@ -182,8 +182,13 @@
PATHS ${PYTORCH_LINK_DIRS}
NO_CMAKE_FIND_ROOT_PATH)
+find_library(FBJNI_LIBRARY fbjni
+ PATHS ${PYTORCH_LINK_DIRS}
+ NO_CMAKE_FIND_ROOT_PATH)
+
target_link_libraries(${PROJECT_NAME}
${PYTORCH_LIBRARY})
+ ${FBJNI_LIBRARY})
```
If your CMakeLists.txt file is located in the same directory as your build.gradle, `set(build_DIR ${CMAKE_SOURCE_DIR}/build)` should work for you. But if you have another location of it, you may need to change it.