compiling many .c files in to one .o file
Hi,
I want to compile more than one source files (.c files) in to a single object file (.o) file. i am using gcc compiler version |
To do that you will need make a "Makefile" which is basicaly instructions to tell the computer how to compile a program.
Here are a few tutorials... http://vertigo.hsrl.rutgers.edu/ug/make_help.html http://www.opussoftware.com/tutorial/TutMakefile.htm http://www.gnu.org/software/make/ also... www.google.com/linux |
You don't necessarily need a make-file. You can just tell gcc to use multiple source files like so:
gcc -o out.obj file1.c file2.c file3.c |
All times are GMT -5. The time now is 02:15 PM. |