What is sharedUserId in Android, and how is it used?

By default, Android assigns a user id to an application. It is the unique id for your application and means that nobody except the user with this id can reach your application’s resources. You cannot access the data of an other application or run it in your current process. when, from an activity, an activity … Read more

Difference between CMake and NDK-build in android studio project

To clear up some confusion here: ndk-build is a build system included in the NDK. It uses Android.mk files. The NDK itself is a collection of compilers and libraries that are needed to build C/C++ code for Android. ndk-build and cmake both use the NDK. What is the actual difference between CMake and NDK build … Read more

aarch64-linux-android-strip file Missing

I have Android Studio 3.1.2 and after I approved the IDE suggested updates I got the next errors: org.gradle.api.tasks.TaskExecutionException: Execution failed for task ‘…’. Caused by: org.gradle.process.internal.ExecException: A problem occurred starting process ‘command ‘/Users/…/Library/Android/sdk/ndk-bundle/toolchains/mips64el-linux-android-4.9/prebuilt/darwin-x86_64/bin/mips64el-linux-android-strip’ Caused by: net.rubygrapefruit.platform.NativeException: Could not start ‘/Users/…/Library/Android/sdk/ndk-bundle/toolchains/mips64el-linux-android-4.9/prebuilt/darwin-x86_64/bin/mips64el-linux-android-strip’ Caused by: java.io.IOException: Cannot run program “/Users/…/Library/Android/sdk/ndk-bundle/toolchains/mips64el-linux-android-4.9/prebuilt/darwin-x86_64/bin/mips64el-linux-android-strip” (in directory “/Users/…/…/…/app”): error=2, No such file … Read more

How to pass C structs back and forth to Java code in JNI?

You need to create a Java class with the same members as C struct, and ‘map’ them in the C code via methods env->GetIntField, env->SetIntField, env->GetFloatField, env->SetFloatField, and so on – in short, lots of manual labor, hopefully there already exist programs that do it automatically: JNAerator (http://code.google.com/p/jnaerator) and SWIG (http://www.swig.org/). Both have their pros … Read more

[INSTALL_FAILED_NO_MATCHING_ABIS: Failed to extract native libraries, res=-113]

July 25, 2019 : I was facing this issue in Android Studio 3.0.1 : After checking lots of posts, here is Fix which works: Go to module build.gradle and within Android block add this script: splits { abi { enable true reset() include ‘x86’, ‘x86_64’, ‘armeabi’, ‘armeabi-v7a’, ‘mips’, ‘mips64’, ‘arm64-v8a’ universalApk true } } Simple … Read more

Gradle sync failed, NDK not configured, download it with SDK manager

disclaimer: I work on Android Studio With newer version (3.6+) of Android Gradle Plugin, please download with “NDK (Side by side)” option from the SDK manager and then specify ndkVersion in the build.gradle with the full version of NDK that is locally available from your machine. For example, after you downloaded NDK 20.1.5948944 under “NDK … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)