PDA

View Full Version : compiling in c



rob21
February 5th, 2008, 07:33 PM
whenever I compile two files in a program named driver in a gnu compiler with the following "gcc -g -o driver driver.c list.c", I get the message "driver not a file or directory". Help, what can I do.
thanks

lnostdal
February 5th, 2008, 07:38 PM
could you paste the output of running ls in your project directory and your call to gcc .. and include the output of gcc please?

jrothwell97
February 5th, 2008, 07:50 PM
Try putting your source files before the switches, such as -g and -o. IE:


gcc driver.c list.c -o driver -g