-
Notifications
You must be signed in to change notification settings - Fork 258
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cmake toolchain doesn't work with cmake 3.7+ #254
Comments
I'll take a closer look tomorrow, but just FYI you shouldn't need to pass |
I tried command without -DANDROID_TOOLCHAIN, and got the some result. |
I assumed as much, but was worth a shot. |
I have changed the cmake version to 3.6.3, and It works. |
I had the same issue and solved it in the same way (downgrade to 3.6.3), can you perhaps document that cmake 3.7.1 does not work? Although at this point it reminds me of a certain other build system... |
We should at least document this. I don't know if the Studio team is planning on updating CMake or not. |
I have the same question when cmake is 3.7.1 |
This is something we're scheduled to talk about in the next Android C++ meeting, but December is a pretty difficult month to actually make meetings happen in :) I'll hopefully have some answers in a couple weeks. |
FYI, I think for the short term anyway that answer is going to continue being "you need to use the cmake that comes with the SDK", but we should at least get some docs in place to make that clear. |
…chain android/ndk#254 opencc crashes when using gcc build breaks when using clang under cmake-3.7.1 So we should use clang under cmake-3.6 now.
Okay, the Studio folks are going to look in to getting support for vanilla (not the Studio fork) cmake. There are some changes that need to get upstreamed and possibly some more work that needs to be done for the new version, so we don't know when this is going to be available, but it is something we're investigating. |
Okay, we have a tracking bug on the Studio side now: http://b.android.com/231562 Closing this one since afaik there's nothing to actually be done for the NDK on this. |
Why is it a studio-only issue? There's a cmake toolchain file: |
Ah, I thought it was only a problem when used via Studio. I guess I have some work to do then. |
https://cmake.org/cmake/help/v3.7/manual/cmake-toolchains.7.html#cross-compiling-for-android CMake now supports Cross Compiling for Android with simple toolchain files. |
Merged into r15. Will be in beta 2. |
Test: ./validate.py # With cmake 3.7 in path Bug: android/ndk#254 Change-Id: Ic9aaf181a508fea7d2b454d902d36e6498a3500b (cherry picked from commit e14807b)
Test: ./validate.py # With cmake 3.7 in path Bug: android/ndk#254 Change-Id: Ic9aaf181a508fea7d2b454d902d36e6498a3500b
The CMake toolchain shipped with the NDK doesn't work with CMake-3.7.2 or 3.9.1. To ensure compatibility, use the shipped cmake binary. See android/ndk#254 or https://gitlab.kitware.com/cmake/cmake/issues/16708 as well as android/ndk#504 Change-Id: I31366cd813edc44d0e62021872c63d9fc06ffb7c
…chain android/ndk#254 opencc crashes when using gcc build breaks when using clang under cmake-3.7.1 So we should use clang under cmake-3.6 now.
I'm using cmake with ndkr13b, and have a problem of selecting clang toolchain.
If I provide -DANDROID_TOOLCHAIN=gcc, cmake works fine. But with the default clang toolchain, cmake still shows the message "-- Android: Selected GCC toolchain 'arm-linux-androideabi-4.9'", and won't pass the compiler check.
Here's my cmake command. Did I miss something?
The text was updated successfully, but these errors were encountered: