* Bash: Cannot execute binary file
@ 2011-03-29 1:34 independentt
2011-03-29 1:37 ` Eliot Moss
2011-03-29 1:38 ` Christopher Faylor
0 siblings, 2 replies; 12+ messages in thread
From: independentt @ 2011-03-29 1:34 UTC (permalink / raw)
To: cygwin
Ok here is my problem I used to be able to run bIRCD on a shell before. But
now first time I try cygwin, I WGET
http://ircd.bircd.org/bewareircd-linux.tar.gz and unzip it, edit the config
files. And now I try to execute it using (.) ./BIRCD and it says BASH:
Cannot execute binary file. I have full access to the file and when I type
file bircd it says ELF 32-bit LSB executable, Intel 80386, version 1
(GNU/Linux), statically linked, stripped.
I am a windowsx86 vista user
Hope you help me thanks.
--
View this message in context: http://old.nabble.com/Bash%3A-Cannot-execute-binary-file-tp31263793p31263793.html
Sent from the Cygwin list mailing list archive at Nabble.com.
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Bash: Cannot execute binary file
2011-03-29 1:34 Bash: Cannot execute binary file independentt
@ 2011-03-29 1:37 ` Eliot Moss
2011-03-29 1:42 ` independentt
2011-03-29 1:38 ` Christopher Faylor
1 sibling, 1 reply; 12+ messages in thread
From: Eliot Moss @ 2011-03-29 1:37 UTC (permalink / raw)
To: cygwin
On 3/28/2011 8:27 PM, independentt wrote:
>
> Ok here is my problem I used to be able to run bIRCD on a shell before. But
> now first time I try cygwin, I WGET
> http://ircd.bircd.org/bewareircd-linux.tar.gz and unzip it, edit the config
> files. And now I try to execute it using (.) ./BIRCD and it says BASH:
> Cannot execute binary file. I have full access to the file and when I type
> file bircd it says ELF 32-bit LSB executable, Intel 80386, version 1
> (GNU/Linux), statically linked, stripped.
> I am a windowsx86 vista user
I could be off-base, but two quick thoughts:
1) Do the file permissions include x (executable) permission
as shown by ls -l?
2) Above you used ./BIRCD and bircd interchangeably for the names,
but in cygwin names can be case-sensitive. Have you tried the
case (upeer vs. lower) of the letters of the name exactly as
ls reports?
Best wishes -- Eliot Moss
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Bash: Cannot execute binary file
2011-03-29 1:34 Bash: Cannot execute binary file independentt
2011-03-29 1:37 ` Eliot Moss
@ 2011-03-29 1:38 ` Christopher Faylor
2011-03-29 2:28 ` independentt
1 sibling, 1 reply; 12+ messages in thread
From: Christopher Faylor @ 2011-03-29 1:38 UTC (permalink / raw)
To: cygwin
On Mon, Mar 28, 2011 at 06:27:57PM -0700, independentt wrote:
>
>Ok here is my problem I used to be able to run bIRCD on a shell before. But
>now first time I try cygwin, I WGET
>http://ircd.bircd.org/bewareircd-linux.tar.gz and unzip it, edit the config
>files. And now I try to execute it using (.) ./BIRCD and it says BASH:
>Cannot execute binary file. I have full access to the file and when I type
>file bircd it says ELF 32-bit LSB executable, Intel 80386, version 1
>(GNU/Linux), statically linked, stripped.
If you go to http://cygwin.com/ and look under "...isn't it?" you'll see:
Cygwin is not:
* a way to run native Linux apps on Windows. You must rebuild your
application from source if you want it to run on Windows.
If file says "ELF 32-bit LSB executable, Intel 80386 version 1
(GNU/Linux)", it means it's a Linux file. That means that you have to
build a Cygwin/Windows version of bircd. What you have is not a Cygwin
version.
cgf
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Bash: Cannot execute binary file
2011-03-29 1:37 ` Eliot Moss
@ 2011-03-29 1:42 ` independentt
2011-03-29 1:53 ` Eliot Moss
0 siblings, 1 reply; 12+ messages in thread
From: independentt @ 2011-03-29 1:42 UTC (permalink / raw)
To: cygwin
Eliot Moss wrote:
>
> On 3/28/2011 8:27 PM, independentt wrote:
>>
>> Ok here is my problem I used to be able to run bIRCD on a shell before.
>> But
>> now first time I try cygwin, I WGET
>> http://ircd.bircd.org/bewareircd-linux.tar.gz and unzip it, edit the
>> config
>> files. And now I try to execute it using (.) ./BIRCD and it says BASH:
>> Cannot execute binary file. I have full access to the file and when I
>> type
>> file bircd it says ELF 32-bit LSB executable, Intel 80386, version 1
>> (GNU/Linux), statically linked, stripped.
>> I am a windowsx86 vista user
>
> I could be off-base, but two quick thoughts:
>
> 1) Do the file permissions include x (executable) permission
> as shown by ls -l?
>
> 2) Above you used ./BIRCD and bircd interchangeably for the names,
> but in cygwin names can be case-sensitive. Have you tried the
> case (upeer vs. lower) of the letters of the name exactly as
> ls reports?
>
> Best wishes -- Eliot Moss
>
> --
> Problem reports: http://cygwin.com/problems.html
> FAQ: http://cygwin.com/faq/
> Documentation: http://cygwin.com/docs.html
> Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
>
>
>
ls -l bircd shows this message
-rwxr-xr-x 1 Admin01 None 577660 Aug 13 2010 bircd
I meant i did ./bircd in the fist case
Thanks for reply
--
View this message in context: http://old.nabble.com/Bash%3A-Cannot-execute-binary-file-tp31263793p31263824.html
Sent from the Cygwin list mailing list archive at Nabble.com.
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Bash: Cannot execute binary file
2011-03-29 1:42 ` independentt
@ 2011-03-29 1:53 ` Eliot Moss
0 siblings, 0 replies; 12+ messages in thread
From: Eliot Moss @ 2011-03-29 1:53 UTC (permalink / raw)
To: cygwin
I think Chris nailed it: cygwin != unix
Best -- Eliot Moss
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Bash: Cannot execute binary file
2011-03-29 1:38 ` Christopher Faylor
@ 2011-03-29 2:28 ` independentt
2011-03-29 3:19 ` Christopher Faylor
0 siblings, 1 reply; 12+ messages in thread
From: independentt @ 2011-03-29 2:28 UTC (permalink / raw)
To: cygwin
Christopher Faylor-8 wrote:
>
> On Mon, Mar 28, 2011 at 06:27:57PM -0700, independentt wrote:
>>
>>Ok here is my problem I used to be able to run bIRCD on a shell before.
But
>>now first time I try cygwin, I WGET
>>http://ircd.bircd.org/bewareircd-linux.tar.gz and unzip it, edit the
config
>>files. And now I try to execute it using (.) ./BIRCD and it says BASH:
>>Cannot execute binary file. I have full access to the file and when I type
>>file bircd it says ELF 32-bit LSB executable, Intel 80386, version 1
>>(GNU/Linux), statically linked, stripped.
>
> If you go to http://cygwin.com/ and look under "...isn't it?" you'll see:
>
> Cygwin is not:
>
> * a way to run native Linux apps on Windows. You must rebuild your
> application from source if you want it to run on Windows.
>
> If file says "ELF 32-bit LSB executable, Intel 80386 version 1
> (GNU/Linux)", it means it's a Linux file. That means that you have to
> build a Cygwin/Windows version of bircd. What you have is not a Cygwin
> version.
>
> cgf
>
> --
> Problem reports: http://cygwin.com/problems.html
> FAQ: http://cygwin.com/faq/
> Documentation: http://cygwin.com/docs.html
> Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
>
>
>
how do I build a cygwin version of bircd?
--
View this message in context: http://old.nabble.com/Bash%3A-Cannot-execute-binary-file-tp31263793p31263838.html
Sent from the Cygwin list mailing list archive at Nabble.com.
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Bash: Cannot execute binary file
2011-03-29 2:28 ` independentt
@ 2011-03-29 3:19 ` Christopher Faylor
2011-03-29 8:40 ` Eliot Moss
0 siblings, 1 reply; 12+ messages in thread
From: Christopher Faylor @ 2011-03-29 3:19 UTC (permalink / raw)
To: cygwin
On Mon, Mar 28, 2011 at 06:42:32PM -0700, independentt wrote:
>how do I build a cygwin version of bircd?
If you're asking me: I don't know. But, your first place to check would
be the bircd.org web site.
cgf
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Bash: Cannot execute binary file
2011-03-29 3:19 ` Christopher Faylor
@ 2011-03-29 8:40 ` Eliot Moss
2011-03-29 9:12 ` Buchbinder, Barry (NIH/NIAID) [E]
0 siblings, 1 reply; 12+ messages in thread
From: Eliot Moss @ 2011-03-29 8:40 UTC (permalink / raw)
To: cygwin
Why not just use the Windows version and invoke it from
cygwin (if cygwin is the environment from which you
want to do that)? It is easy to invoke Windows programs
from cygwin; you just need to remember to format any
arguments in the form the Windows program wants. To
that end, cygpath is a useful utility, e.g.:
function acrobat () {
command acrobat $(cygpath -wa ${1})
}
in your .bashrc file allows you to invoke Windows
acrobat with a path rewritten from cygwin format
to Windows format. This can be improved to check for
presence of the argument ${1}, etc., but perhaps
you get the idea.
Best wishes -- Eliot Moss
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
^ permalink raw reply [flat|nested] 12+ messages in thread
* RE: Bash: Cannot execute binary file
2011-03-29 8:40 ` Eliot Moss
@ 2011-03-29 9:12 ` Buchbinder, Barry (NIH/NIAID) [E]
2011-08-27 5:55 ` srinu
0 siblings, 1 reply; 12+ messages in thread
From: Buchbinder, Barry (NIH/NIAID) [E] @ 2011-03-29 9:12 UTC (permalink / raw)
To: cygwin, 'moss@cs.umass.edu'
Eliot Moss sent the following at Monday, March 28, 2011 10:28 PM
>Why not just use the Windows version and invoke it from cygwin (if
>cygwin is the environment from which you want to do that)? It is easy
>to invoke Windows programs from cygwin; you just need to remember to
>format any arguments in the form the Windows program wants. To that end,
>cygpath is a useful utility, e.g.:
>
>function acrobat () { }
> command acrobat $(cygpath -wa ${1})
>}
>
>in your .bashrc file allows you to invoke Windows acrobat with a path
>rewritten from cygwin format to Windows format. This can be improved to
>check for presence of the argument ${1}, etc., but perhaps you get the
>idea.
- You should probably also add some quotes, in case your paths have spaces.
- A complete path to acrobat will avoid needing to have it in your path.
- Using cygstart will get you back to your command prompt.
function acrobat () {
if [ -f "${1}" ]
then
cygstart '/path/acrobat' "$(cygpath -wa "${1}")"
else
echo "error: file `${1}' not found!"
fi
}
Note: I have not tested the above. Debugging is left as an exercise for
the user.
- You also might look at cyg-wrapper.sh, found here:
http://hermitte.free.fr/cygwin/
Note: I don't use it so YMMV.
Good luck.
- Barry
Disclaimer: Statements made herein are not made on behalf of NIAID.
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Bash: Cannot execute binary file
2011-03-29 9:12 ` Buchbinder, Barry (NIH/NIAID) [E]
@ 2011-08-27 5:55 ` srinu
2011-08-27 8:08 ` Marco atzeri
2011-08-27 8:17 ` Jens Schweikhardt
0 siblings, 2 replies; 12+ messages in thread
From: srinu @ 2011-08-27 5:55 UTC (permalink / raw)
To: cygwin
Buchbinder, Barry (NIH/NIAID) [E] <BBuchbinder <at> niaid.nih.gov> writes:
>
> Eliot Moss sent the following at Monday, March 28, 2011 10:28 PM
> >Why not just use the Windows version and invoke it from cygwin (if
> >cygwin is the environment from which you want to do that)? It is easy
> >to invoke Windows programs from cygwin; you just need to remember to
> >format any arguments in the form the Windows program wants. To that end,
> >cygpath is a useful utility, e.g.:
> >
> >function acrobat () { }
> > command acrobat $(cygpath -wa ${1})
> >}
> >
> >in your .bashrc file allows you to invoke Windows acrobat with a path
> >rewritten from cygwin format to Windows format. This can be improved to
> >check for presence of the argument ${1}, etc., but perhaps you get the
> >idea.
>
> - You should probably also add some quotes, in case your paths have spaces.
> - A complete path to acrobat will avoid needing to have it in your path.
> - Using cygstart will get you back to your command prompt.
>
> function acrobat () {
> if [ -f "${1}" ]
> then
> cygstart '/path/acrobat' "$(cygpath -wa "${1}")"
> else
> echo "error: file `${1}' not found!"
> fi
> }
>
> Note: I have not tested the above. Debugging is left as an exercise for
> the user.
>
> - You also might look at cyg-wrapper.sh, found here:
> http://hermitte.free.fr/cygwin/
> Note: I don't use it so YMMV.
>
> Good luck.
>
> - Barry
> Disclaimer: Statements made herein are not made on behalf of NIAID.
>
>
Hi,
This problem is very frequently occuring irrespective of executable.
A new laptop, windows7, downloaded the Cygwin with utmostcare in slecetingthe
desired and permissions.
Wrote simple programe in c ( simple such that: print "hello world").
while try to run the executable created throws the error: cannot execute
binary file.
flow is like follows:
C file created: Hello.c ( full permissions)
Compiled and linked: gcc -c Hello.c -o helloTest
chmod 777 helloTest
./helloTest
bash: ./helloTest : cannot execute binary file
Tried all options which I know, googled no clue.
I tried in other machines too, same error.
I think something is missing, earlier used to work on my old system. But last
few months I tried several times reinstalling, new machines which I got for
personal use.
Is there any solution or inputs please.
regards,
ramana
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Bash: Cannot execute binary file
2011-08-27 5:55 ` srinu
@ 2011-08-27 8:08 ` Marco atzeri
2011-08-27 8:17 ` Jens Schweikhardt
1 sibling, 0 replies; 12+ messages in thread
From: Marco atzeri @ 2011-08-27 8:08 UTC (permalink / raw)
To: cygwin
On 8/27/2011 7:50 AM, srinu wrote:
> Buchbinder, Barry (NIH/NIAID) [E]<BBuchbinder<at> niaid.nih.gov> writes:
>
>>
>> Eliot Moss sent the following at Monday, March 28, 2011 10:28 PM
>>> Why not just use the Windows version and invoke it from cygwin (if
>>> cygwin is the environment from which you want to do that)? It is easy
>>> to invoke Windows programs from cygwin; you just need to remember to
>>> format any arguments in the form the Windows program wants. To that end,
>>> cygpath is a useful utility, e.g.:
>>>
>>> function acrobat () { }
>>> command acrobat $(cygpath -wa ${1})
>>> }
>>>
>>> in your .bashrc file allows you to invoke Windows acrobat with a path
>>> rewritten from cygwin format to Windows format. This can be improved to
>>> check for presence of the argument ${1}, etc., but perhaps you get the
>>> idea.
>>
>> - You should probably also add some quotes, in case your paths have spaces.
>> - A complete path to acrobat will avoid needing to have it in your path.
>> - Using cygstart will get you back to your command prompt.
>>
>> function acrobat () {
>> if [ -f "${1}" ]
>> then
>> cygstart '/path/acrobat' "$(cygpath -wa "${1}")"
>> else
>> echo "error: file `${1}' not found!"
>> fi
>> }
>>
>> Note: I have not tested the above. Debugging is left as an exercise for
>> the user.
>>
>> - You also might look at cyg-wrapper.sh, found here:
>> http://hermitte.free.fr/cygwin/
>> Note: I don't use it so YMMV.
>>
>> Good luck.
>>
>> - Barry
>> Disclaimer: Statements made herein are not made on behalf of NIAID.
>>
>>
>
> Hi,
>
> This problem is very frequently occuring irrespective of executable.
> A new laptop, windows7, downloaded the Cygwin with utmostcare in slecetingthe
> desired and permissions.
> Wrote simple programe in c ( simple such that: print "hello world").
> while try to run the executable created throws the error: cannot execute
> binary file.
>
> flow is like follows:
> C file created: Hello.c ( full permissions)
> Compiled and linked: gcc -c Hello.c -o helloTest
> chmod 777 helloTest
> ./helloTest
> bash: ./helloTest : cannot execute binary file
>
> Tried all options which I know, googled no clue.
> I tried in other machines too, same error.
>
> I think something is missing, earlier used to work on my old system. But last
> few months I tried several times reinstalling, new machines which I got for
> personal use.
>
> Is there any solution or inputs please.
>
> regards,
> ramana
start from here:
> Problem reports: http://cygwin.com/problems.html
further questions:
- local disk or network disk ?
- results of "ls -l helloTest" ?
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Bash: Cannot execute binary file
2011-08-27 5:55 ` srinu
2011-08-27 8:08 ` Marco atzeri
@ 2011-08-27 8:17 ` Jens Schweikhardt
1 sibling, 0 replies; 12+ messages in thread
From: Jens Schweikhardt @ 2011-08-27 8:17 UTC (permalink / raw)
To: cygwin
On Sat, Aug 27, 2011 at 05:50:06AM +0000, srinu wrote:
# Hi,
#
# This problem is very frequently occuring irrespective of executable.
# A new laptop, windows7, downloaded the Cygwin with utmostcare in slecetingthe
# desired and permissions.
# Wrote simple programe in c ( simple such that: print "hello world").
# while try to run the executable created throws the error: cannot execute
# binary file.
#
# flow is like follows:
# C file created: Hello.c ( full permissions)
# Compiled and linked: gcc -c Hello.c -o helloTest
You get what you asked for with -c, an object file. Instead use
gcc Hello.c -o helloTest
which creates an executable.
Regards,
Jens
--
Jens Schweikhardt http://www.schweikhardt.net/
SIGSIG -- signature too long (core dumped)
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2011-08-27 8:17 UTC | newest]
Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-03-29 1:34 Bash: Cannot execute binary file independentt
2011-03-29 1:37 ` Eliot Moss
2011-03-29 1:42 ` independentt
2011-03-29 1:53 ` Eliot Moss
2011-03-29 1:38 ` Christopher Faylor
2011-03-29 2:28 ` independentt
2011-03-29 3:19 ` Christopher Faylor
2011-03-29 8:40 ` Eliot Moss
2011-03-29 9:12 ` Buchbinder, Barry (NIH/NIAID) [E]
2011-08-27 5:55 ` srinu
2011-08-27 8:08 ` Marco atzeri
2011-08-27 8:17 ` Jens Schweikhardt
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).