Did you know LQ has a Linux Hardware Compatibility List?
Go Back > Forums > Linux Forums > Linux - General
User Name
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.


  Search this Thread
Old 05-29-2002, 12:26 PM   #1
LQ Newbie
Registered: Feb 2002
Posts: 12

Rep: Reputation: 0
Smile Cygwin commands execution

Hi everybody,

Well I installed Cygwin in my computer but there is something that I don't understand.

Well it seems that the only commands I can execute are the ones located in the default directory "/cygwin/bin/"

so I compiled a small code in C and try to execute the out put but I could from the directori were I was, so I copy this executable file to the "/cyg/bin/" directory and the I could execute it.

So anybody knows how can I execute any command from any directory?

Thank you for your time.
Old 05-29-2002, 12:45 PM   #2
Registered: May 2002
Location: dracut MA
Distribution: Ubuntu; PNE-LE; LFS (no book)
Posts: 598

Rep: Reputation: 109Reputation: 109
I've been using cygwin for a year now, and I have no problem executing code from any directory. Are you putting a "./" infront of your executable and are you compiling it with gcc? Also, is it a real executable or is it object/byte-compiled code. Sorry for the stupid questions, but sometimes people make foolish mistakes (Like wondering why a filesystem wouldn't show up...turns out in my 3 am daze, I forgot to __make__ the filesystem...oops)
Old 05-29-2002, 12:48 PM   #3
LQ Newbie
Registered: Feb 2002
Posts: 12

Original Poster
Rep: Reputation: 0
Thanks Orgcandman, using ./ before the command (it is an output of the gcc compiler) executes the .exe file.
Old 05-29-2002, 08:19 PM   #4
Registered: May 2002
Posts: 179

Rep: Reputation: Disabled
another option is setting the $PATH attribute. by default it is set to /cygwin/bin, but you can change that thusly:
export PATH=/cygwin/bin:/path/to/exe:/other/path



Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 On
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
deny commands execution pthug Linux - General 1 09-18-2005 03:12 PM
Pause Execution in VB ashirazi Programming 2 08-17-2005 07:17 PM
How to tell where the execution is going on right now? bahadur Programming 7 04-03-2005 04:42 AM
Help with Cygwin, using Linux commands and installing files Delmarc Linux - Newbie 4 10-25-2003 10:37 PM
Timed Execution Undead Programming 5 09-13-2001 03:57 AM

All times are GMT -5. The time now is 04:35 PM.

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