Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to port native c code on android

Tags:

c

android

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,

like image 801
manju Avatar asked Jan 11 '11 10:01

manju


People also ask

Can you run C code on Android?

You can add C and C++ code to your Android project by placing the code into a cpp directory in your project module. When you build your project, this code is compiled into a native library that Gradle can package with your app.

How do I open a .C file on Android?

To Install and Use C/C++ compiler in Termux (in Termux clang is the C/C++ compiler) , Download & Install Termux from : Play Store. After Installing execute this command pkg install clang. After Successfully installing clang you can compile C/C++ scripts.

What C library does Android use?

Bionic is an implementation of the standard C library, developed by Google for its Android operating system.

What is Android native code?

Android native code is C/C++.


1 Answers

I have found the solution here is the start..

http://integratingstuff.com/2010/12/12/calling-native-c-code-through-jni-in-android-applications/

http://mindtherobot.com/blog/452/android-beginners-ndk-setup-step-by-step/

like image 130
manju Avatar answered Sep 20 '22 06:09

manju