-
Notifications
You must be signed in to change notification settings - Fork 16
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
terminating with uncaught exception of type std::bad_cast: std::bad_cast #517
Comments
See #517 for explanation An update to the Github Action virtual environment added NDK r22, which CMake uses, ignoring $ANDROID_NDK_HOME. Solution: Remove NDK r22 and update to latest NDK r21f
* chore: Fix redirect created when a new version is released Previous link was broken * chore: Remove untranslated strings from messages (#496) Reduces memory use and APK size * chore(CI): Update JDK setup action (#505) * note to use specific ndk version * chore: Improve contributor docs (#509) * chore: Added instructions to build translations and run the Javascript bundler prior to building for Android * chore: Added instructions for downloading and preparing offline maps wth the needed structure * chore: Add detailed instructions on how to download maps and add them to phone * chore: Add note about react-native run-android not opening bundler on all machines * chore: Add note about com.mapeo changing with different release versions * chore: Change asar to full flag name * fix: Localize "Import Config" button (#510) * fix: Change hardcoded message to intl FormattedMessage * Add missing string to translations * chore: prettier * extract messages Co-authored-by: Gregor MacLennan <[email protected]> * feat: Updated translations (vi, es, po) (#498) * New translations en.json (Vietnamese) * New translations en.json (Vietnamese) * New translations en.json (Vietnamese) * New translations en.json (Portuguese, Brazilian) * New translations en.json (Portuguese, Brazilian) * New translations en.json (Portuguese, Brazilian) * New translations en.json (Spanish) * New translations en.json (Portuguese, Brazilian) Co-authored-by: Gregor MacLennan <[email protected]> * fix: Fix import config button crash (#512) * fix: Fix import config button crash * Update version in package-lock Co-authored-by: luandro <[email protected]> * chore: Fix Github CI builds by removing NDK r22 (#516) See #517 for explanation An update to the Github Action virtual environment added NDK r22, which CMake uses, ignoring $ANDROID_NDK_HOME. Solution: Remove NDK r22 and update to latest NDK r21f * fix: Write preset tags to observations (#514) * fix: Add better variable naming and easier to understand logic * fix: Cleaner and easier to understand logic on updating tags * fix: Clean redundant code and sort updated value order in preparation for edge cases * fix: Fix cutoff of text on OnePlus6T phone #502 (#511) * fix: Fix cutoff of text on OnePlus6T phone #502 Use a custom Text component with fontFamily explicitly set, to work around bug facebook/react-native#15114 (comment) * Fix implementation of style merging * fix bugs * feat: Add French translations * feat: Add Sranan Tongo translations * feat: Add Dutch translations * fix: Update Thai, Khmer & Vietnamese translations * feat: Updated translations for default configuration (vi, srn) * Revert "feat: Updated translations for default configuration (vi, srn)" This reverts commit c267a99. Install was done using npm@7 which changed the package-lock format and broke the build * chore: Re-apply c267a99 with correct npm@6 version and lockfile v1 * chore: Prepare release v5.2.0 Co-authored-by: Kira Oakley <[email protected]> Co-authored-by: luandro <[email protected]> Co-authored-by: Digidem Bot <[email protected]>
@gmaclennan has this been addressed? |
In a sense yes. The bug that remains is "Having NDK v22 installed during build-time will cause crash at runtime". The work-around is to delete NDK v22 before building. Android SDK allows several versions of NDK to be installed at the same time, and the build should select the correct version based on Gradle config, but this is not working. This is a bug for people that need to have NDK v22 installed for other projects they are working on. |
Going to track in #744, closing here. |
If Mapeo is failing to start, or quitting on startup, and you see this error in the logs (by running
npm run log
), then it is likely due to problems with NDK versions in the build.CMake is used to build native modules for Node (leveldown and sodium) and it seems that CMake has a different mechanism for resolving which NDK version to use to Android.
Android has 3 mechanisms for specifying NDK versions:
android.ndkversion
inbuild.gradle
ANDROID_NDK_HOME
environment variableANDROID_NDK_ROOT
environment variableSome CI environments can specify one (or more) of these environment variables, and it seems like different tools will prioritize differently which one to use.
In addition, it seems like CMake can ignore all of these, and default to using the latest NDK version installed. If you search through the build logs for references to NDK you should see conflicts of versions e.g.
shows that CMake is using ndk r22 for the toolchain, even though everything else is configured to use r21. The workaround seems to be to delete all higher NDK versions before trying to build.
A more robust solution would be to find how to specify which NDK version CMake should use.
The text was updated successfully, but these errors were encountered: