Compile in Fedora and run on Android

Is it possible to compile a c code in Fedora and to run it on Android with gcc? I tried to compile using gcc file.c -o f1 and it didn't work. Any seggustions? I was unable to execute it with ADB tool.

Answers


If your c code is run in terminal, you can simple cross compile it and push the executable file to your phone by using ADB tools.

  1. get a cross compiler

  2. use arm-eabi-gcc for compiling your c code , generate executable file ie. a.out

  3. adb push a.out /sdcard, chmod 777, then you can run it from adb shell

Need Your Help

How to get UITextField Tap Event?

iphone objective-c ios ipad ios-universal-app

I am trying to show UIAlertView on Tap or Click of UITextField for both IPad and IPhone. I make an IBAction and Attach it with Tap Down event of UITextField.

How to add Facebook friends upcoming birthdays to my app?

java facebook

I'm working on a calendar app, and I wanted to fetch upcoming birthdays from Facebook, so I read about it and found that i need to create App using Facebook's Graph API explorer, I did, but it didn't