This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: newbie question on linking classes


Hi Koyel,

You are compiling and linking source.cpp.

You need to compile and link all your source code.

e.g.
g++ source.cpp uno.cpp dos.cpp tres.cpp -o myapp

If you do your compiling separate from your linking:
g++ source.o uno.o dos.o tres.o -o myapp

HTH,
--Eljay


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]