LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 03-28-2010, 10:51 PM   #1
kakikomi
LQ Newbie
 
Registered: Mar 2010
Location: 東南アジア
Posts: 3

Rep: Reputation: 0
Executable unable to run


This is what I have done. I cross compiled a simple C++ "hello world" application in Cygwin that targets an embedded machine running uclinux on powerpc405. I can see that it is an ELF file. So I transefered the executable to the target machine. When I attempted to run the executable I get

-sh: ./a.out: not found

I can swear that the file is indeed where it is. May I have so some help/hint to the problem causing this?
 
Old 03-28-2010, 11:13 PM   #2
robertstar20
LQ Newbie
 
Registered: Mar 2010
Posts: 2

Rep: Reputation: 0
Use

$ ls ./a.out

..to confirm if the file is there or not. If it's not, use

$ ls

..to see which files are there. I suspect Cygwin has named the file a.exe instead of a.out?
 
Old 03-28-2010, 11:48 PM   #3
kakikomi
LQ Newbie
 
Registered: Mar 2010
Location: 東南アジア
Posts: 3

Original Poster
Rep: Reputation: 0
Yes the file exist and I am not running it in Cygwin but in the embedded machine. The executable was crossed compiled
 
Old 03-29-2010, 03:07 AM   #4
Valery Reznic
ELF Statifier author
 
Registered: Oct 2007
Posts: 676

Rep: Reputation: 137Reputation: 137
Quote:
Originally Posted by kakikomi View Post
Yes the file exist and I am not running it in Cygwin but in the embedded machine. The executable was crossed compiled
What's output of
Code:
ldd ./a.out
on embedded system ?
 
Old 03-30-2010, 02:38 AM   #5
kakikomi
LQ Newbie
 
Registered: Mar 2010
Location: 東南アジア
Posts: 3

Original Poster
Rep: Reputation: 0
Oh...I get the idea, you suggest that I find out the shared libraries my program is using. Unfortunately the embedded machine does not have ldd. so I used objdump on the development host to list out the shared libraries used and it seems that the libraries required are not on the target machine. Guess that`s the problem.

Thanks.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
cannot get an executable to run... disruptive Linux - Newbie 5 03-04-2008 11:18 AM
unable to set executable context rado.ovcarcik Fedora 3 02-23-2006 04:55 AM
an executable that does not run jgoggel Programming 2 07-22-2004 07:54 PM
Unable to logon on as non-root user after update as unable to set executable context pls198 Fedora 2 04-09-2004 11:41 AM
How do I run my executable?? scott7500 Programming 2 12-30-2001 04:22 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 07:17 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration