i m trying to debug my jni section of application by running ngk-gdb on windows machine with android-ndk-r8b.
i am using cygwin and c/c++ plugin for eclipse.my device is galaxy s, android 2.3.7
what i did is followed the instructions on Using Eclipse for Android C/C++ Debugging,
but i am stuck on running ndk-gdb, getting this error:
Device CPU ABIs: armeabi-v7a armeabi
ERROR: The device does not support the application's targetted CPU ABIs!
Device supports: armeabi-v7a armeabi
Package supports:
thx for your help
I encountered the problem recently and in my case it was a cygwin issue. make was not installed in cygwin and this created problems further along in the ndk-gdb script. After installing make using the cygwin setup.exe (select make under Devel - on another recommendation, I also installed tcsh under Shells), the "ABIS targetted by application:" line shows the app's targeted ABI.
Without make:
/cygdrive/c/work/android/android-ndk-r8b-windows/android-ndk-r8b/ndk-gdb: line 105: make: command not found
ABIs targetted by application:
Device API Level: 15
Device CPU ABIs: armeabi-v7a armeabi
ERROR: The device does not support the application's targetted CPU ABIs!
Device supports: armeabi-v7a armeabi
Package supports:
With make properly installed:
ABIs targetted by application: armeabi-v7a
Device API Level: 15
Device CPU ABIs: armeabi-v7a armeabi
Compatible device ABI: armeabi-v7a
Application.mk, located in the jni folder, can be used to specify the app's targeted ABI - an example:
APP_ABI := armeabi-v7a
APP_OPTIM := debug
Good luck!
For all others like me with Nexus (devices) updated with Android 4.3 there are bugs that hinder Native code debugging. (I tried everything found on SO :)
Either root your device and try
Or Update nexus 4.3 factory image here (and this is reported working by google android dev)
Or wait for Android 4.4 update to come to your device (as bug is identified and fix in the source tree by Google by not yet packaged
released)
Related
I want to install wine using a remote terminal. My main limitation is that I can't use sudo, or apt-get. To install wine, I am following the steps described here. When I run the command /configure --enable-win64, I get:
(...)
configure: MinGW compiler not found, cross-compiling PE files won't be supported.
configure: libXxf86vm 64-bit development files not found, XFree86 Vidmode won't be supported.
configure: libOSMesa 64-bit development files not found (or too old), OpenGL rendering in bitmaps won't be supported.
configure: OpenCL 64-bit development files not found, OpenCL won't be supported.
configure: pcap 64-bit development files not found, wpcap won't be supported.
configure: libdbus 64-bit development files not found, no dynamic device support.
configure: libsane 64-bit development files not found, scanners won't be supported.
configure: libusb-1.0 64-bit development files not found (or too old), USB devices won't be supported.
configure: libgphoto2 64-bit development files not found, digital cameras won't be supported.
configure: libgphoto2_port 64-bit development files not found, digital cameras won't be auto-detected.
configure: gstreamer-1.0 base plugins 64-bit development files not found, GStreamer won't be supported.
configure: OSS sound system found but too old (OSSv4 needed), OSS won't be supported.
configure: libudev 64-bit development files not found, plug and play won't be supported.
configure: libSDL2 64-bit development files not found, SDL2 won't be supported.
configure: libcapi20 64-bit development files not found, ISDN won't be supported.
configure: libcups 64-bit development files not found, CUPS won't be supported.
configure: libopenal 64-bit development files not found (or too old), OpenAL won't be supported.
configure: libnetapi not found, Samba NetAPI won't be supported.
configure: Finished. Do 'make' to compile Wine.
I understand that I need a MinGW compiler first. Every search I do on how to install it leads to using sudo or apt-get, which I can't do.
So my question is, how to install gcc-mingw from sources or without using sudo, apt-get??
Thank you.
I recently tried add extensions in ExoPlayer like ffmpeg extension to support more audio formats in my app, i followed the extension-ffmpeg Readme.md and i successfully created the library for arm64-v8a, armeabi-v7a, x86 and x86_64 and inside of these folders are libavcodec.so, libavutil.so and libswresample.so, After successfully creating the library i need to build the aar to include it in my app but when i run
cd "${FFMPEG_EXT_PATH}" && \
${NDK_PATH}/ndk-build APP_ABI="armeabi-v7a arm64-v8a x86 x86_64" -j4
i get this error
Android NDK: WARNING: APP_PLATFORM android-16 is higher than android:minSdkVersion 1 in ./AndroidManifest.xml. NDK binaries will *not* be compatible with devices older than android-16. See https://android.googlesource.com/platform/ndk/+/master/docs/user/common_problems.md for more information.
Android NDK: Your APP_BUILD_SCRIPT points to an unknown file: ./jni/Android.mk
/home/oni/Android/Sdk/ndk/20.0.5594570/build/core/add-application.mk:88: *** Android NDK: Aborting... . Stop.
I'm a newbie to this and i have tried to see some examples of Android.mk for exoplayer ffmpeg extensions but i did no find anything and i'm stuck in this part, i'm still searching for some examples that might help me to successful build the extension ffmpeg aar.
My program uses the linux/uinput.h header. This header file is included in the arm64 android ndk standalone toolchain (generated with this command in the android ndk folder: python.exe ./make_standalone_toolchain.py --arch arm64 --install-dir arm64 --deprecated-headers --stl gnustl), but not in the 32-bit arm one, generated the same way. This is a problem, because I need to use the header. I tried to copy the header across (some research showed that the architecture doen't matter with the uinput header), but then I get this error:
sysroot\usr\include\linux\uinput.h:71:15: error: 'ABS_CNT' undeclared here (not in a function)
__s32 absmax[ABS_CNT];
^
What's going on? Why is the header not included in the 32-bit toolchain, and why is the exact same header file getting an error when copied across?
I worked it out - it's a known bug in the Android NDK r16. I needed to use unified headers and use this flag when compiling:
-D__ANDROID_API__=21
I'm novice in cross-compiling and just started to cross-compile packages on my linux machine (amd64) for host (NAS) with ARMv5 (linux kernel 2.6.31.8). I installed crosstool-ng and with it created toolchain for compilation for ARM. According to some tutorials online I succeeded to compile x264 package. But now when I try to run it, I was given the following error message
./x264: /lib/libm.so.6: version 'GLIBC_2.15' not found (required by ./x264)
Ok now I see that I need libm library but what it is and how to compile x264 with it?
From the error message: the version of x264 you built requires version of glibc 2.15. The Glibc is built as part of your cross compilation toolchain (through crosstool-ng).
You need to build a new toolchain with the same version of glibc found on your NAS root filesystem (or compatible).
(edited after #NotLikeThat comment)
I am trying to build libusb with android ndk on Ubuntu 12.10.
I type in the ndk-build command and it fails on compiling io.c with the following error.
jni/libusb/io.c:34:25: fatal error: sys/timerfd.h: No such file or directory
Where can I get timerfd.h? Isn't it supposed to come with Linux kernel
the function that you are searching has nothing to do with the "Linux-kernel"!
This funktion belongs to the C-language.
On Android devices the clib is crippled ( sorry: stripped ) down to the minimum
and is called bionic.
Check the net for more infos on that toppic
Good luck
Martin