-
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
[BUG] NDK 23.0 with CMake 3.21: "clang++ is not able to compile a simple test program" #1560
Comments
Reduced test case (CMake must be 3.21+):
The difference is that our toolchain was automatically pulling up android-16 to android-21 for LP64 targets. AGP doesn't do that, nor does CMake. I'm not sure if we can work around that or if AGP just needs to stop asking for configurations that don't exist. Triaged to r23b to at least figure that out. If it requires an AGP fix we probably need to disable it by default for a year or so while AGP catches up. |
It looks like the new toolchain doesn't do any of the API level clamping the old one did. I'm guessing that wasn't intentional. |
The fix needed a fix: https://android-review.googlesource.com/c/platform/ndk/+/1826816/. Whoever does the cherry-picks make sure you get both :) |
Test: added test Bug: android/ndk#1560 Change-Id: If5fbba07e1c3630ef1b2766c684288ca07294ff6 (cherry picked from commit 29519e9)
When not specified this was evaluating to an empty string, so CMake was receiving only one argument... Test: added a test Bug: android/ndk#1560 Change-Id: I1340a7b0afd271568c5f8aadbc4ca345479e95fa (cherry picked from commit eaaf499)
Fixed in r23b. |
Description
Build error:
Defining
ANDROID_USE_LEGACY_TOOLCHAIN_FILE=ON
fixes the problem.Test case:
https://github.com/scapix-com/example1
Open folder
ui/android
Remove
ANDROID_USE_LEGACY_TOOLCHAIN_FILE=ON
to see the error.Environment Details
The text was updated successfully, but these errors were encountered: