Tag: android-ndk

How do I run valgrind with an Android app?

I’ve installed valgrind for android and I can confirm it is working as I tried running ls with it, and it works fine. But how do I execute an android app with a native component I would like to debug? I looked at this question: How to start an android app with valgrind but I […]

Android NDK: Error: must be enabled with the -std=c++11 or -std=gnu++11 compiler options

I am trying to use one big c++ library in my android application. I am using eclipse with android ndk plugin. When I run it, I got this error message; This file requires compiler and library support for the ISO C++ 2011 standard.This support is currently experimental, and must be enabled with the -std=c++11 or […]

Send C++ string to Java via JNI

I am working on the C++ side of a project that is building an Android application. There is some information (via strings and string arrays) that I need to pass to the Java application (via JNI). I have never done this before, and the people working in the reverse direction have no experience with C++ […]

unicode support in android ndk

I have a large C/C++ library that I need to use as part of an Android NDK project. This library needs to be able to intelligently process UTF8 strings (for example, conversion to lowercase/uppercase). The library has conditional compilation to punt to an OS API to do the conversion, but there don’t seem to be […]

Can't run ndk-build on Android studio from gradle on osx yosemite

I am trying to run ndk-build from my build.gradle in an Android Studio 1.0 project on MAC OSX Yosemite. task ndkBuild(type: Exec) { commandLine ‘ndk-build’, ‘-C’, file(‘src/main’).absolutePath } I have specified the ndk-dir in the local.properties file but I am getting this error A problem occurred starting process ‘command ‘ndk-build’ If I run the gradle […]

stack traces stop before getting to my code (on Android using NDK)

I’m developing on Android 2.3.x using NDK r5b. Occasionally my code crashes and I’d like to know where. I already know how to get the corresponding line in my application when I have a have a pointer (i.e. from Android’s stack traces.) However, oftentimes I see useless stack traces like this (full stack trace): #00 […]

List of supported native code of Android phones

Is there any list of Android phones and their supported native code? For example I want to know which phones support only armeabi and which support armeabi-v7a. The latter is important because I’m doing a lot of floating-point calculation in native code.

Android NDK, two Static Libraries and Linking

I started off creating libraries as shared libraries, but I considered it would be more efficient to create one shared libraries and the rest static. When it was all shared, it compiled and linked fine, but moving to static, I get on linking “undefined reference”. Edit: I build all the libraries in one Android.mk Android.mk: […]

Power-Off or Restart an android device via Code/Program?

Is there any way to restart/shutdown a phone directly from an application? For Example: I need to restart/shutdown my Phone when i meet some specific condition… Citations to Developer Website: Permission to Reboot? http://developer.android.com/reference/android/Manifest.permission.html#REBOOT Permission to Brick the device??? http://developer.android.com/reference/android/Manifest.permission.html#BRICK Method to reboot??? http://developer.android.com/reference/android/os/PowerManager.html#reboot%28java.lang.String%29 Method to reboot and Wipe?? http://developer.android.com/reference/android/os/RecoverySystem.html#rebootWipeUserData%28android.content.Context%29 Reboot Method in MonkeyRunner/MonkeyDevice: http://developer.android.com/guide/developing/tools/MonkeyDevice.html#reboot […]

Building FFMPEG with librtmp for android

I’m trying to build all-in-one static binary of FFMPEG with NDK r7b and everything works fine untill i try to build it with RTMP support. I’m usind sources from https://github.com/guardianproject/android–ffmpeg with librtmp2.4 and custom config like this .configure \ –target-os=linux \ –cross-prefix=arm-linux-androideabi- \ –arch=arm \ –sysroot=/home/andrey/android-ndk-r7b/platforms/android-3/arch-arm \ –enable-static \ –disable-shared \ –disable-symver \ –enable-small \ […]

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