The linked OpenCV prebuilt references are undefined. Example of one of the compilation errors: ORB_SLAM2::ORBextractor::ComputeKeyPointsOctTreeEveryLevel(int, std::__ndk1::vector<std::__ndk1::vector<cv::KeyPoint, std::__ndk1::allocator<cv::KeyPoint> >, std::__ndk1::allocator<std::__ndk1::vector<cv::KeyPoint, std::__ndk1::allocator<cv::KeyPoint> > > >&)': /home/dev/workspace/repositories/ORB-SLAM2-based-AR-on-Android/app/.cxx/cmake/release/arm64-v8a/../../../../src/main/cpp/ORB/src/ORBextractor.cc:812: undefined reference to 'cv::FAST(cv::_InputArray const&, std::__ndk1::vector<cv::KeyPoint, std::__ndk1::allocator<cv::KeyPoint> >&, int, bool)' /home/dev/workspace/repositories/ORB-SLAM2-based-AR-on-Android/app/.cxx/cmake/release/arm64-v8a/../../../../src/main/cpp/ORB/src/ORBextractor.cc:817: undefined reference to 'cv::FAST(cv::_InputArray const&, std::__ndk1::vector<cv::KeyPoint, std::__ndk1::allocator<cv::KeyPoint> >&, int, bool)' libORBSLAM2.a(ORBextractor.cc.o): In function 'ORB_SLAM2::ORBextractor::ComputeKeyPointsOctTree(std::__ndk1::vector<std::__ndk1::vector<cv::KeyPoint, std::__ndk1::allocator<cv::KeyPoint> >, std::__ndk1::allocator<std::__ndk1::vector<cv::KeyPoint, std::__ndk1::allocator<cv::KeyPoint> > > >&)
In addition, the existing OpenCV 320 shared library prebuilt is not compatible with the latest Android Studio requirements and Android build tool LLVM C++11 compiler. Prebuilts of OpenCV 3.2.0 as static STL type, Android ABI arm64-v8a with native API levels android-29 and android-25 are available for download on: https://github.com/maximaging/opencv-3.2.0-android-prebuilts
Updated OpenCV dependencies in CMakeLists.txt.
Fixed few compilation issues related to unsupported functionalities with the recent Android Studio (Gradle plugin) changes.
ORB_SLAM2::ORBextractor::ComputeKeyPointsOctTreeEveryLevel(int, std::__ndk1::vector<std::__ndk1::vector<cv::KeyPoint, std::__ndk1::allocator<cv::KeyPoint> >, std::__ndk1::allocator<std::__ndk1::vector<cv::KeyPoint, std::__ndk1::allocator<cv::KeyPoint> > > >&)': /home/dev/workspace/repositories/ORB-SLAM2-based-AR-on-Android/app/.cxx/cmake/release/arm64-v8a/../../../../src/main/cpp/ORB/src/ORBextractor.cc:812: undefined reference to 'cv::FAST(cv::_InputArray const&, std::__ndk1::vector<cv::KeyPoint, std::__ndk1::allocator<cv::KeyPoint> >&, int, bool)' /home/dev/workspace/repositories/ORB-SLAM2-based-AR-on-Android/app/.cxx/cmake/release/arm64-v8a/../../../../src/main/cpp/ORB/src/ORBextractor.cc:817: undefined reference to 'cv::FAST(cv::_InputArray const&, std::__ndk1::vector<cv::KeyPoint, std::__ndk1::allocator<cv::KeyPoint> >&, int, bool)' libORBSLAM2.a(ORBextractor.cc.o): In function 'ORB_SLAM2::ORBextractor::ComputeKeyPointsOctTree(std::__ndk1::vector<std::__ndk1::vector<cv::KeyPoint, std::__ndk1::allocator<cv::KeyPoint> >, std::__ndk1::allocator<std::__ndk1::vector<cv::KeyPoint, std::__ndk1::allocator<cv::KeyPoint> > > >&)