Android: Difference between revisions

517 bytes added ,  16 January 2010
→‎Fix headers: Add log.h header fix
(→‎Fix headers: Add log.h header fix)
Line 60: Line 60:
Certain header files in the NDK do not compile as C++. Paste this command in your terminal while in the NDK directory to patch them.
Certain header files in the NDK do not compile as C++. Paste this command in your terminal while in the NDK directory to patch them.


  patch -p1 << "EOF"
  patch -Np1 << "EOF"
  --- tmp/android-ndk-1.6_r1/build/platforms/android-4/arch-arm/usr/include/asm-generic/siginfo.h   2009-07-28 17:26:01.000000000 -0700
  --- android-ndk-1.6_r1-orig/build/platforms/android-4/arch-arm/usr/include/android/log.h 2009-07-28 17:26:01.000000000 -0700
  +++ android-ndk-1.6_r1/build/platforms/android-4/arch-arm/usr/include/asm-generic/siginfo.h       2009-12-09 11:48:46.000000000 -0800
+++ android-ndk-1.6_r1/build/platforms/android-4/arch-arm/usr/include/android/log.h 2010-01-15 17:37:23.000000000 -0800
@@ -85,7 +85,7 @@
      ANDROID_LOG_WARN,
      ANDROID_LOG_ERROR,
      ANDROID_LOG_FATAL,
-    ANDROID_LOG_SILENT,    /* only for SetMinPriority(); must be last */
+    ANDROID_LOG_SILENT    /* only for SetMinPriority(); must be last */
  } android_LogPriority;
 
  /*
--- android-ndk-1.6_r1-orig/build/platforms/android-4/arch-arm/usr/include/asm-generic/siginfo.h 2009-07-28 17:26:01.000000000 -0700
  +++ android-ndk-1.6_r1/build/platforms/android-4/arch-arm/usr/include/asm-generic/siginfo.h 2010-01-15 17:37:10.000000000 -0800
  @@ -55,7 +55,7 @@
  @@ -55,7 +55,7 @@
   struct {
   struct {
Line 72: Line 83:
   int _sys_private;
   int _sys_private;
   } _timer;
   } _timer;
  --- tmp/android-ndk-1.6_r1/build/platforms/android-4/arch-arm/usr/include/dlfcn.h 2009-07-28 17:26:01.000000000 -0700
  --- android-ndk-1.6_r1-orig/build/platforms/android-4/arch-arm/usr/include/dlfcn.h 2009-07-28 17:26:01.000000000 -0700
  +++ android-ndk-1.6_r1/build/platforms/android-4/arch-arm/usr/include/dlfcn.h     2009-12-09 11:51:20.000000000 -0800
  +++ android-ndk-1.6_r1/build/platforms/android-4/arch-arm/usr/include/dlfcn.h 2010-01-15 17:37:10.000000000 -0800
  @@ -42,7 +42,7 @@
  @@ -42,7 +42,7 @@
     RTLD_LAZY = 1,
     RTLD_LAZY = 1,
 
     RTLD_LOCAL  = 0,
     RTLD_LOCAL  = 0,
  -  RTLD_GLOBAL = 2,
  -  RTLD_GLOBAL = 2,
  +  RTLD_GLOBAL = 2
  +  RTLD_GLOBAL = 2
   };
   };
 
   #define RTLD_DEFAULT  ((void*) 0xffffffff)
   #define RTLD_DEFAULT  ((void*) 0xffffffff)
  EOF
  EOF
134

edits