On Thu, 03 Jul 2003 16:29:08 +1000, Kieran Simpson wrote:
> I have written a set of C++ classes that I would like to compile into a
> library file, that then can be linked into other projects so I can use those
> classes. The only thing is that I am not to sure how make the classes into
> a library, and then how to consequently link them into my other projects.
> Can anybody point me in the right direction please. I want to statically
> link them so that the code is compiled into the app, because I don't want to
> mess with DLL's
>
> Thanks
Only compile the file, do not link it. Then, link the object files (.obj
on windows, or .o on UNIX), and you have the binary ready. You will have
to put the declarations in the headers (.h files), while definitions in
the .cpp files and compile those .cpp files.
-Dhruv.
|