Android: support NDK16#10515
Merged
opencv-pushbot merged 9 commits intoopencv:masterfrom Jan 12, 2018
Merged
Conversation
This makes it possible to compile OpenCV with for instance ndk-r16
Compiler message: tif_unix.c:170:12: error: call to 'mmap' declared with attribute error: mmap is not available with _FILE_OFFSET_BITS=64 when using GCC until android-21. Either raise your minSdkVersion, disable _FILE_OFFSET_BITS=64, or switch to Clang.
…DK_CCACHE)
To prevent this result:
/usr/bin/ccache ccache <android-ndk-r16.1>/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-gcc ...
with:
ccache: error: Recursive invocation (the name of the ccache binary must be "ccache")
To use 'z' in Android.mk instead of absolute path from the build machine.
Avoids this error message with CMake 3.10: CMake Error: CMake was unable to find a build program corresponding to "Ninja". CMAKE_MAKE_PROGRAM is not set. You probably need to select a different build tool. Related changes is that pkg-config tool is found (/usr/bin/pkg-config).
mshabunin
approved these changes
Jan 12, 2018
Contributor
|
👍 Thank you for this, much appreciated ! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
CMAKE_MAKE_PROGRAMin case of (-GNinja): Explaination for build_sdk.py #10448BTW, Binaries size of OpenCV Android SDK with NDK r16 is about ~3Gb (NDK r10 ~800Mb). Most part of this impact is related to static .a files.