PocketMagic

PocketMagic

Where Technology meets magic


Android
45 Posts
BlackBerry
3 Posts
Electronics
68 Posts
Hardware
120 Posts
High Voltage
49 Posts
iPhone
4 Posts
Linux
2 Posts
Nuclear
20 Posts
Optics
11 Posts
Photography
7 Posts
Photoshop
3 Posts
Research
19 Posts
Reviews
18 Posts
Robotics
8 Posts
Security
7 Posts
Software
72 Posts
Symbian
2 Posts
Tubes
18 Posts
Windows
3 Posts
Windows Mobile
11 Posts

Top Articles!       See PocketMagic on Facebook


uRADMonitor - Online Radiation monitoring station | 14745 Views | Rate 70.55
uRADMonitor - Online Radiation monitoring station
NMEA GPS Library for AVR Microcontrollers | 4738 Views | Rate 57.78
NMEA GPS Library for AVR Microcontrollers
Bluetooth and iOS - Use Bluetooth in your iPhone apps | 17529 Views | Rate 57.28
Bluetooth and iOS - Use Bluetooth in your iPhone apps
Repairing a Victoreen CDV-700 6B Dosimeter  | 105 Views | Rate 52.5
Repairing a Victoreen CDV-700 6B Dosimeter
Building a robot – Part 2 | 4479 Views | Rate 44.79
Building a robot – Part 2
Programmatically Injecting Events on Android - Part 2 | 4792 Views | Rate 44.37
Programmatically Injecting Events on Android - Part 2
Simple Switched power Supplies | 15716 Views | Rate 41.14
Simple Switched power Supplies
CDV-742 Dosimeter and CDV-750 Dosimeter Charger | 78 Views | Rate 39
CDV-742 Dosimeter and CDV-750 Dosimeter Charger

 
  

Android NDK Cygwin make error 127


By Radu Motisan Posted on November 18th, 2010 , 692 Views (Rate 0.76)



  




I have three computers with the Android NDK environment configured identically, according to these instructions.
On one of them, when I start the Cygwin shell to build my project with "ndk-build" I get make error 127:
android_ndk_make_error_127
The other two computers work just fine and compiles the JNI code as expected.

To see more details, retry the build, using:

  1.  
  2. ndk-build NDK_LOG=1 V=1
  3.  

I now see the build fails at the arm-eabi-gcc:

  1.  
  2. me@basic ~
  3. # ndk-build NDK_LOG=1 V=1
  4. Android NDK: NDK installation path auto-detected: '/cygdrive/d/work_code/android
  5. /android-ndk-r4b'
  6. Android NDK: GNU Make version 3.81 detected
  7. Android NDK: Host OS was auto-detected: windows
  8. Android NDK: Host CPU was auto-detected: x86
  9. Android NDK: HOST_TAG set to windows
  10. Android NDK: Host awk tool was auto-detected: awk
  11. Android NDK: Host awk test returned: Pass
  12. Android NDK: This NDK supports the following toolchains and target ABIs:
  13. Android NDK: arm-eabi-4.2.1: armeabi
  14. Android NDK: arm-eabi-4.4.0: armeabi armeabi-v7a
  15. Android NDK: x86-4.2.1: x86
  16. Android NDK: Found supported platforms: android-3 android-4 android-5 android-8
  17. Android NDK: PLATFORM android-3 supports: arm
  18. Android NDK: ABI arm sysroot is: /cygdrive/d/work_code/android/android-ndk-r4b
  19. /build/platforms/android-3/arch-arm
  20. Android NDK: PLATFORM android-4 supports: arm
  21. Android NDK: ABI arm sysroot is: /cygdrive/d/work_code/android/android-ndk-r4b
  22. /build/platforms/android-4/arch-arm
  23. Android NDK: PLATFORM android-5 supports: arm x86
  24. Android NDK: ABI arm sysroot is: /cygdrive/d/work_code/android/android-ndk-r4b
  25. /build/platforms/android-5/arch-arm
  26. Android NDK: ABI x86 sysroot is: /cygdrive/d/work_code/android/android-ndk-r4b
  27. /build/platforms/android-5/arch-x86
  28. Android NDK: PLATFORM android-8 supports: arm x86
  29. Android NDK: ABI arm sysroot is: /cygdrive/d/work_code/android/android-ndk-r4b
  30. /build/platforms/android-8/arch-arm
  31. Android NDK: ABI x86 sysroot is: /cygdrive/d/work_code/android/android-ndk-r4b
  32. #
  33. Android NDK: Found stable platform levels: 3 4 5 8
  34. Android NDK: Found max platform level: 8
  35. Android NDK: Found project path: /cygdrive/d/work_code/android/JNIProiect
  36. Android NDK: Parsing /cygdrive/d/work_code/android/android-ndk-r4b/build/core/de
  37. fault-application.mk
  38. Android NDK: Found APP_PLATFORM=android-7 in /cygdrive/d/work_code/android/Blu
  39. eInput/default.properties
  40. Android NDK: Adjusting APP_PLATFORM to android-5
  41. Android NDK: Using build script /cygdrive/d/work_code/android/JNIProiect/jni/An
  42. droid.mk
  43. Android NDK: Application 'local' is not debuggable
  44. Android NDK: Selecting release optimization mode (app is not debuggable)
  45. Android NDK: Building application 'local' for ABI 'armeabi'
  46. Android NDK: Using target toolchain 'arm-eabi-4.4.0' for 'armeabi' ABI
  47. rm -f /cygdrive/d/work_code/android/JNIProiect/libs/armeabi/lib*.so /cygdrive/d/w
  48. ork_code/android/JNIProiect/libs/armeabi-v7a/lib*.so /cygdrive/d/work_code/androi
  49. d/JNIProiect/libs/x86/lib*.so
  50. rm -f /cygdrive/d/work_code/android/JNIProiect/libs/armeabi/gdbserver /cygdrive/d
  51. /work_code/android/JNIProiect/libs/armeabi-v7a/gdbserver /cygdrive/d/work_code/an
  52. droid/JNIProiect/libs/x86/gdbserver
  53. rm -f /cygdrive/d/work_code/android/JNIProiect/libs/armeabi/gdb.setup /cygdrive/d
  54. /work_code/android/JNIProiect/libs/armeabi-v7a/gdb.setup /cygdrive/d/work_code/an
  55. droid/JNIProiect/libs/x86/gdb.setup
  56. Compile thumb : JNIProiect <= /cygdrive/d/work_code/android/JNIProiect/jni/BlueIn
  57. put.c
  58. /cygdrive/d/work_code/android/android-ndk-r4b/build/prebuilt/windows/arm-eabi-4.
  59. 4.0/bin/arm-eabi-gcc -I/cygdrive/d/work_code/android/android-ndk-r4b/build/platf
  60. orms/android-5/arch-arm/usr/include -fpic -mthumb-interwork -ffunction-sections
  61. -funwind-tables -fstack-protector -fno-short-enums -D__ARM_ARCH_5__ -D__ARM_ARCH
  62. _5T__ -D__ARM_ARCH_5E__ -D__ARM_ARCH_5TE__ -Wno-psabi -march=armv5te -mtune=xsc
  63. ale -msoft-float -mthumb -Os -fomit-frame-pointer -fno-strict-aliasing -finline-
  64. limit=64 -I/cygdrive/d/work_code/android/JNIProiect/jni -DANDROID -Wa,--noexecs
  65. tack -O2 -DNDEBUG -g -c -MMD -MP -MF /cygdrive/d/work_code/android/JNIProiect/obj
  66. /local/armeabi/objs/JNIProiect/JNIProiect.o.d /cygdrive/d/work_code/android/BlueIn
  67. put/jni/JNIProiect.c -o /cygdrive/d/work_code/android/JNIProiect/obj/local/armeabi
  68. /objs/JNIProiect/JNIProiect.o
  69. make: *** [/cygdrive/d/work_code/android/JNIProiect/obj/local/armeabi/objs/BlueIn
  70. put/JNIProiect.o] Error 127
  71.  
  72. me@basic ~
  73. #
  74.  

Manually opening arm-eabi-gcc.exe in d:\work_code\android\android-ndk-r4b\build\prebuilt\windows\arm-eabi-4.4.0\bin\ fails with "The procedure entry point __ctype_ptr__could not be located in the dynamic link library cygwin1.dll." :
arm-eabi-gcc-error
In this case the problem is that cygwin1.dll located in the cygwin installation folder was not found. To fix this add the cygwin/bin folder to your system's environment path variable:
cywin_path

This still doesn't help, I get error 127 again. Copying the cygwin1.dll where the arm-eabi-gcc.exe is, seems to help but running the build script again results in Error 1. So this is not a solution.





A quick research on the internet shows this is a popular issue. Some say you need to reinstall Cygwin, others blame the NDK package. No use.

If I try to compile a C file to native executable, using the Makefile script presented here, it fails with error 127. I don't have more time to waste on time, but I assume is some kind of conflict with other development tools I have installed on this machine (MS VS, etc).

This machine also fails to connect to the Android properly, via USB, I get lots of timeouts and disconnects on large data volume. I've presented that issue here.

Should you find a solution, let me know.






  

More on PocketMagic:

Tube: USN-5J29 | 285 Views | Rate 28.5
Tube: USN-5J29
Programmatically Injecting Events on Android - Part 1 | 9890 Views | Rate 25.76
Programmatically Injecting Events on Android - Part 1
Tube: 1B40 | 227 Views | Rate 25.22
Tube: 1B40
Atmega8 and enc28J60 for ethernet support | 7054 Views | Rate 24.16
Atmega8 and enc28J60 for ethernet support
How to set the AVR Fusebits | 1619 Views | Rate 23.81
How to set the AVR Fusebits
ATMega128 and HD44780 LCD using 3 Wires with the 74HC164 | 1983 Views | Rate 23.06
ATMega128 and HD44780 LCD using 3 Wires with the 74HC164

Thank you for commenting. Your comment won't show until approved, which can take some time.

Please copy the string rjqvUG to the field below: