Tag: android-ndk

NDK Integration in Android Studio Error

I am using Android studio version 1.3.1 and try to integrate the NDK by going to local.proprties and writing ndk.dir= and I got this error Error:Execution failed for task ‘:tesstwo:compileReleaseNdk’. Error: NDK integration is deprecated in the current plugin. Consider trying the new experimental plugin. For details, see http://tools.android.com/tech-docs/new-build-system/gradle-experimental. Set “android.useDeprecatedNdk=true” in gradle.properties to continue […]

Gradle doesn't package gdbserver into apk. ndk-gdb results in “ERROR: Non-debuggable application installed on the target device”

In Android Studio 0.6 I created an android test project with a very simple C function wrapped with the JNI. I set android:debuggable=”true” in the AndroidManifest.xml. I ran ndk-build NDK_DEBUG=1. This generated a gdbserver and a gdb.setup file in the correct location. However, when I built the project in Android studio, and ran ndk-gdb –debug […]

How to package native commandline application in apk?

I would like to package an Android native commandline application into an apk. I have the application building with ndk-build which uses jni/Android.mk. The output is in libs/armeabi/<MyApp>. I also have the apk building with ant. However, the apk does not seem to pick up the commandline application. If I unzip the apk the app […]

Generating .so files in Android Studio 1.0.2 with NDK

I have been working on getting a very simple NDKSample application built as per the walk-through here. My problem is, I cannot get Android Studio to generate the .so files, so I have no libraries. I understand that NDK Support is deprecated now and there will be an alternative provided early this year, however there […]

Compile and use ABI-dependent executable binaries in Android with Android Studio 2.2 and CMake

I’m testing out the new Android Studio C/C++ building via CMake through stable gradle (http://tools.android.com/tech-docs/external-c-builds). In my app, an already rooted device needs to use an ABI-dependent binary that I compile inside Android Studio. When I try to compile a standard library with add_library(mylib SHARED mylib.c) it gets automatically compiled and copied inside the lib/[ABI] […]

When/why does my Java singleton instance get destroyed?

I have an android app that is setup to start a Java activity (call it MyJavaActivity), which in turn launches a NativeActivity. When the NativeActivity finishes it returns back to MyJavaActivity. I also have a Java singleton class (call it MyJavaSingleton) which I would like to stay in memory throughout my application’s lifecycle. I set […]

Possible to Override system .so library in App

I have to modify the Http Live Streaming implementation of Android Media Player. The implementation is under the stagefright library http://androidxref.com/4.0.4/xref/frameworks/base/media/libstagefright/httplive/LiveDataSource.cpp I think these library will compile to a libstagefright.so which should be part of the Android system. My question is if I make some changes to this library and compile a new libstagefright.so. If […]

Android NDK Debugging

The Android NDK documentation doesn’t seem all that clear to me as to what sequence of commands you run to get debugging information into, and out of the ndk-gdb executable which is provided. If there is a format for what lines to break on, and in what file, is there a specification somewhere? If so, […]

android update project –path “command not found”

I’m trying to develop an app using OCR that runs on Android. I am following the steps in http://gaut.am/making-an-ocr-android-app-using-tesseract/ I have passed the “ndk-build” step and advanced to the “android update project –path .” step . But it shows “android: command not found error”. I am new to android development. Can anyone please tell me […]

The ant/ folder is suddenly missing from Android SDK. Did Google remove it?

I’ve tried compiling libreoffice core project (choosing Android module) (with make, no Gradle involved yet), and I’m getting this error: /home/aleksandar/libreoffice/workdir/UnpackedTarball/owncloud_android_lib/build.xml:90: Cannot find /home/aleksandar/Android/Sdk/tools/ant/build.xml imported from /home/aleksandar/libreoffice/workdir/UnpackedTarball/owncloud_android_lib/build.xml When looking through my SDK, I realized that /Sdk/tools/ant folder doesn’t even exist. Is this the way that it should be? I’m not sure why it causes that […]

Android Babe is a Google Android Fan, All about Android Phones, Android Wear, Android Dev and Android Games Apps and so on.