Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8553623
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T14:41:41+00:00 2026-06-11T14:41:41+00:00

I compiled simple file main.cpp using android-ndk-r8b : #include <stdio.h> #include <stdlib.h> int main(void)

  • 0

I compiled simple file main.cpp using android-ndk-r8b:

#include <stdio.h>
#include <stdlib.h>

int main(void) {
    puts("!!!Hello World!!!");
    return EXIT_SUCCESS;
}

I used command as follow:

…/android-ndk-r8b/ndk-build APP_ABI=x86

from the directory of main.cpp file
My Android.mk file:

LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
LOCAL_CFLAGS += -fPIC
LOCAL_MODULE := main
LOCAL_SRC_FILES := main.cpp
include $(BUILD_EXECUTABLE)

Then I tried to open this file on debian x86 and I have this information:

./main: No such file or directory

then I used command:

ld main

and had information:

ld: error in main(.eh_frame); no .eh_frame_hdr table will be created.
ld: warning: cannot find entry symbol _start; defaulting to 0000000008048320

Is it possible to run file compiled via android-ndk on a common linux x86 distribution?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T14:41:43+00:00Added an answer on June 11, 2026 at 2:41 pm

    No, the Android run-time libraries are not compatible with desktop Linux.

    Note that your ndk-build puts the main executable in ./libs/x86/

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I successfully compiled the following program simple.cc: #include <gtkmm.h> int main (int argc, char
I am unable to compile this simple program #include<stdio.h> #include<conio.h> #include<spawn.h> #include<process.h> int main(){
Say you've got the following simple main.cpp file: #include <cstdlib> #include <iostream> #include <fstream>
Take the following simple source (name it test.cpp): #include <windows.h> void main() { DebugBreak();
I wrote this simple C code and compiled it using Visual Studio 2010, with
Consider the followin simple class definition - // file A.h #include <iostream> class A
Good day! Let us have a source file main.cpp and a CMakeLists.txt file containing
I'm using MSVC++ to program a simple window, and I included a resource file
I created a file containing the following line: int main() { return 0; }
The bare-bones minimal example: #include <boost/iostreams/filtering_stream.hpp> #include <boost/iostreams/filter/bzip2.hpp> int main() { boost::iostreams::filtering_istream in; in.push(boost::iostreams::bzip2_compressor());

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.