-
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
Why NDK r13 android.toolchain.cmake add -fno-exceptions and -fno-rtti? #212
Comments
Same question from my side ... why you turn off a default compiler feature ? |
@chaoren, any idea if this was intentional? It looks like we tried to match the behavior of https://github.com/taka-no-me/android-cmake/blob/master/android.toolchain.cmake#L832, but we don't default the option to ndk-build defaults to no exceptions or RTTI support, so it's possible the goal was to match that. For now, it looks like you can add |
Yep, this is it. I also had a chat with @vharron, and we kind of decided that these are pretty bloaty features to have on by default on Android. |
Sounds reasonable to me. As noted above, |
Why don't you do the other way around? IMHO, disabling rtti and exceptions in the toolchain is simply wrong, this decision can be done in the project cmake scripts if is needed not in the toolchain file. |
This is a very good point. Given that we went with cmake because it's already common in the wild, we should probably be behaving the way all those existing cmake systems expect. I can fix this simply enough on our side, but I'm guessing Studio will auto set this option when configuring a new project, so I'll need to look in to that. |
Thx This is a great help |
And another problem is android.toolchain.cmake could config CMAKE_INSTALL_PATH, so when other project need to find Find***.cmake , it could not work in right way. What should I do ? |
This is in r14 beta 1. |
I will transplant a CMAKE c++ project with typeid and exception , is NDK r13 support these ?
The text was updated successfully, but these errors were encountered: