Q:

gcc compilation problem

Everybody
I have a small problem . I just doing it for experiment. I'm using ubuntu 10.04
my problem is that my c program name 2.c  is at /home/Desktop (location) but my .o files are at different location /tmp/man(location of 3.o) /usr/jan(location of 4.o)
I complied the program form home account by command
gcc"/home/Desktop/2.c""/tmp/man/3.0"/usr/jan/4.0 "

but every time i compile the program it shows error like that
bash: gcc/home/Desktop/2.c/tmp/man/3.0: No such file or directory.

what I'm doing wrong ?
can any body what is the proper way to run the program
one request please don't tell to paste the all file in same folder than use gcc or changind ld_library path .
if You are giving me suggestion about makefile than please give the complete make file .
just tell me how i can compile and run the program ?

A:

First, don't use " to separate the arguments, use spaces. Also, you wrote 3.0 and 4.0 (with zero, not oh). Then, do you want to compile the 2.c file and link it with the 3.o and 4.o files ? You just have to call 
> gcc /home/Desktop/2.c /tmp/man/3.o /usr/jan/4.o -o /your/path/exefile

This will compile 2.c, link it with 3.o and 4.o and build the exefile executable in the specified path.

