7

can anyone tell me how to port a native c program on android platform..should i include some c libraries or how exactly...?

Thanks in advance,

manju
  • 847
  • 3
  • 16
  • 43

4 Answers4

5

Read up on the Android Native Development Kit (NDK)

M.M
  • 138,810
  • 21
  • 208
  • 365
Axarydax
  • 16,353
  • 21
  • 92
  • 151
  • Hi thanks Axary great answer, but 1 small doubt my c code contains the following libraries as it requires root access can i do with NDK..?#include #include #include #include #include #include "fdevent.h" #include "adb.h" #include #include #include – manju Jan 11 '11 at 10:58
  • @manju `unistd.h` Unix/Linux-specific, but there are alternatives (GOOGLE!) –  Jun 08 '14 at 13:19
1

You may find this useful: Using the Android NDK

YPrakash
  • 11
  • 1
1

I have used all those headers in one of my previous Android NDK implementations, except the mman.h and fb.h. However since mman is under sys and fb is part of android source, I guess you should be able to go ahead with it.

Let's know what issues you come across in the process.

BTW, what calls you need from mman.h?

TheCottonSilk
  • 8,662
  • 2
  • 26
  • 37