Member
Registered: Apr 2007
Location: the Rocket City
Distribution: Debian, Ubuntu, CentOS; in days past Fedora, Solaris, SunOS, 4.2BSD, 4.3BSD, SVR4, AIX, HP-UX
Posts: 101
Rep: 
|
First, try "man gcc". Man is your friend.
Second, I believe that gcc leaves its executable output in a file called a.out by default. To produce a different file, use the -o option. For instance, try "gcc foo.c -o foo". That will compile a file "foo.c" and produce an executable "foo". To execute, try "./foo". Of course, use your own filenames rather than "foo".
gcc has many interesting options. Check gcc manuals, particularly man and info.
Phil
Last edited by ordinary; 02-25-2010 at 10:39 AM.
|