Connecting Tech Pros Worldwide Help | Site Map

Compiling & running C programs on Red hat 9.0

  #1  
Old January 5th, 2007, 02:28 PM
Newbie
 
Join Date: Jan 2007
Posts: 1
I recently installed red hat 9.0 on my comp. Wen i try to execute a C program in Vim then it gives error that gcc command not found. The command that i give is:
Expand|Select|Wrap|Line Numbers
  1. gcc <filename1> -o <filename2>
  2.  
on earlier version of red hat this command ws workin, but on 9.0 im gettin error. If anybody can help... thanx!

Last edited by KUB365; January 9th, 2007 at 06:23 AM.
  #2  
Old January 5th, 2007, 09:55 PM
cassbiz's Avatar
Familiar Sight
 
Join Date: Oct 2006
Location: Florida
Posts: 204

re: Compiling & running C programs on Red hat 9.0


I usually run the commands from the shell itself and not through Vim

Depending on what features you have installed you may need to run a " ./ " in front of the command

Expand|Select|Wrap|Line Numbers
  1. -bash-2.05b$ ./gcc <filename.0> ...........
  2.  

Last edited by cassbiz; January 5th, 2007 at 09:56 PM. Reason: typo
  #3  
Old January 8th, 2007, 04:05 AM
Loismustdie129's Avatar
Familiar Sight
 
Join Date: Aug 2006
Posts: 195

re: Compiling & running C programs on Red hat 9.0


I usually run the compiler through the Terminal in Fedora 6. It sounds like you don't have gcc. Did you try to look in your /usr/bin file to see what compiler you have installed.
Reply