The new toolchain file requires Android NDK r12b and above. Default to use 'arm-linux-androideabi-clang' toolchain and LLVM libc++ STL runtime.
Align all the compiler and linker flags according to new ndk-build configuration in Android NDK r12b, i.e. no more '-f[no-]strict-aliasing' and '-f[no-]omit-frame-pointer', but more stringent warnings check.
Improve over the old toolchain file where most of the options are now changeable after the initial configuration. The exceptions are ANDROID_NDK and ANDROID_TOOLCHAIN_NAME due to limitation of CMake.
Close#1441.
Other changes in this commit includes:
- Fix Android sample launcher app to support shared C++ STL runtime library.
- Remove temporary fix in FindUrho3D module as it is not required anymore with our new toolchain file.
- Fix Log::WriteRaw() method to pass the parameters correctly to __android_log_print() function.
- Fix enable_pch() macro to emit -fPIC compiler flags correctly based on target's POSITION_INDEPENDENT_CODE property.
- Fix linker flags for ld.bfd where it needs help to find the location of the rooted shared libraries. The flags are not required for ld.gold but they do no harm for gold linker.
- Enhance the CheckCompilerToolchain module to auto-detect if the NEON SIMD is enabled or not for Android build (based on the chosen ANDROID_ABI).
When in try_compile() mode, quickly obtain the previously cached values stored in the (inner scope) environment variables and bypass all the checks (which are already done when the toolchain file is being processed at the start of CMake run).
Due to the CMake try_compile() limitation, initial build option values (i.e. not env-vars) were not visible to all the CMake checks during inital configuration, preventing the build option from functioning as expected.
After using CMAKE_SYSROOT in the android.toolchain.cmake module, CMake will only find Doxygen when CMAKE_FIND_ROOT_PATH_MODE_PROGRAM is set to to NEVER. It is actually weird why it was working before when it was set to ONLY previously.
Use CMAKE_SYSROOT to manage the sysroot automatically when cross-compiling instead of adding the '--sysroot' flag manually everywhere. We only need to add it manually in places where CMake does not, like in our custom GCC/Clang response file for PCH.
Differentiate between setting up header search path for system headers and for application headers so that GCC/Clang may suppress compilation warnings from the former, if any.
Somehow after bumping up the CMake minimum version, CMake configures Xcode to work "better" with xcpretty that now the warnings are piping through the xcpretty's filter. Unfortunately when performing CI build, this is undesirable because not only now the log size is swelling, the build is slower too.
Some cross-compiling build tree configuration needs native compiler toolchain for host tool building via ExternalProject_Add(). This additional check ensures the native compiler toolchain is available up front before the build tree is even generated. Close#1300.
[ci package]
Commit: 08fd3b7690
Message: Minor documentation expansion on use of std::bind() for events.
commit 873adf5565f8537f9d06f69a649c57635ab1c2de
Merge: 0a19418 f75a784
Author: carnalis <carnalis.j@gmail.com>
Date: Thu Mar 2 14:25:42 2017 -0500
Merge branch 'master' of github.com:carnalis/Urho3D
commit 0a1941814ec656d31bb5399c919ba516a2cda7cb
Author: carnalis <carnalis.j@gmail.com>
Date: Fri Jan 13 21:24:53 2017 -0500
Minor documentation expansion on use of std::bind() for events.
commit f75a784102708998841302c70736be39eeb2300d
Merge: 84a1f82 06d2100
Author: carnalis <carnalis.j@gmail.com>
Date: Thu Mar 2 04:42:56 2017 -0500
Merge branch 'master' of github.com:carnalis/Urho3D
commit 84a1f827752335260b7a5bd6a180613bd018af7e
Author: carnalis <carnalis.j@gmail.com>
Date: Fri Jan 13 21:24:53 2017 -0500
Minor documentation expansion on use of std::bind() for events.
commit 06d210045af24646a6161daeaff28fd9828dccfd
Merge: 20877d0 71e9501
Author: carnalis <carnalis.j@gmail.com>
Date: Fri Jan 20 09:59:31 2017 -0500
Merge branch 'master' of github.com:carnalis/Urho3D
commit 20877d01c805f58234798f6a0b1baeeee1e1628e
Author: carnalis <carnalis.j@gmail.com>
Date: Fri Jan 13 21:24:53 2017 -0500
Minor documentation expansion on use of std::bind() for events.
commit 71e9501934cc9a67eeae1d0c524dbc11a1bd96db
Author: carnalis <carnalis.j@gmail.com>
Date: Fri Jan 13 21:24:53 2017 -0500
Minor documentation expansion on use of std::bind() for events.
commit 873adf5565f8537f9d06f69a649c57635ab1c2de
Merge: 0a19418 f75a784
Author: carnalis <carnalis.j@gmail.com>
Date: Thu Mar 2 14:25:42 2017 -0500
Merge branch 'master' of github.com:carnalis/Urho3D
commit 0a1941814ec656d31bb5399c919ba516a2cda7cb
Author: carnalis <carnalis.j@gmail.com>
Date: Fri Jan 13 21:24:53 2017 -0500
Minor documentation expansion on use of std::bind() for events.
commit f75a784102708998841302c70736be39eeb2300d
Merge: 84a1f82 06d2100
Author: carnalis <carnalis.j@gmail.com>
Date: Thu Mar 2 04:42:56 2017 -0500
Merge branch 'master' of github.com:carnalis/Urho3D
commit 84a1f827752335260b7a5bd6a180613bd018af7e
Author: carnalis <carnalis.j@gmail.com>
Date: Fri Jan 13 21:24:53 2017 -0500
Minor documentation expansion on use of std::bind() for events.
commit 06d210045af24646a6161daeaff28fd9828dccfd
Merge: 20877d0 71e9501
Author: carnalis <carnalis.j@gmail.com>
Date: Fri Jan 20 09:59:31 2017 -0500
Merge branch 'master' of github.com:carnalis/Urho3D
commit 20877d01c805f58234798f6a0b1baeeee1e1628e
Author: carnalis <carnalis.j@gmail.com>
Date: Fri Jan 13 21:24:53 2017 -0500
Minor documentation expansion on use of std::bind() for events.
commit 71e9501934cc9a67eeae1d0c524dbc11a1bd96db
Author: carnalis <carnalis.j@gmail.com>
Date: Fri Jan 13 21:24:53 2017 -0500
Minor documentation expansion on use of std::bind() for events.