-
Notifications
You must be signed in to change notification settings - Fork 442
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
Android dumpster fire, again #310
Comments
Okay, so, i also spent the whole weekend on trying to make this run, and got it sort of running with a hack, which consist on creating a new toolchain file which invokes the official NDK android toolchain and sets the
This assumes your NDK is installed on
With this i was able to build corrade, magnum and my android app. Hope it helps. |
Thanks for the info! 👍 I think this was also the approach suggested by one of the CMake developers in one of the issues linked above -- that they would ditch the builtin support and get the info from the toolchain file bundled in the NDK instead. We'll see how that goes. For now I'm staying on NDK r17, as that's the path of least resistance :) |
Even https://github.com/ruslo/polly doesn't have an r19 android toolchain and it generally has everything! If you get one working then you should contribute it there by adjusting an r18 toolchain to r19 or so! |
AFAIK this issue is not really high priority but just in case anyone needs a dirty workaround, applying the above patch in addition to hpcorona's suggestion |
Looking at the upstream GitLab issues linked above, it seems that they managed to firefight all problems and 3.16 could work with the new NDKs again! And they're deciding against removing upstream support in CMake, which is a great thing to hear as well 🎉 |
As mentioned in mosra/magnum-bootstrap#21, NDK r20 seems to work even with CMake 3.10 if For now, until 3.16 is out, I'm still treating that as an unsupported scenario, the suggestion is to stay on r17 or older for the time being. |
I've just started looking into building for Android. It seems cmake 3.16.2 is now out (https://cmake.org/download/), do we need to update any of the steps for r20 or newer? |
Ideally it would "just work" again, but based on past experience I highly doubt that. I'll need to check. Until then, is it possible for you to stay on r17? |
Staying on r17 isn't too much of a problem, but just a comment that I've been able to build and make the apk successfully with the toolchain file bundled with the ndk. Might just be easier to use the ndk toolchain: https://developer.android.com/ndk/guides/cmake Pasting in the command I'd been using
|
I managed to get things running again with NDK r19 and CMake 3.17. It only needs some extra help with |
Just a followup, the change done in 8bc1fa1 was still partially using the deprecated / compatibility NDK layout, which led to Gradle not being able to find libraries installed inside the NDK. That's fixed as of mosra/corrade@a0db699 and bc0bb07; with CMake 3.20 it's also no longer needed to supply obvious paths to |
As reported on Gitter by @luigytkd, Magnum is unable to build under Android NDK r19 due to erros like
Googling the above doesn't really show anything obvious. NDK r16 is known to work (it's run on Travis CI), NDK r17 (running locally on Arch) works as well. Didn't test with r18 as there's no AUR package. However, when trying to reproduce with r19, I get this during the initial CMake run:
Questions on SO (from end of January) are without answers. Possibly related solution is here, but AFAIK there's no way to force the toolchain path to CMake.
Desperately looking into the CMake bug tracker, I found these two very concerning issues:
Current solution is to go back before r19. r17 (and r16) is known to work well, r18 might work too.
The text was updated successfully, but these errors were encountered: