Re: [Dev-C++] implementation .o procedure
Open Source C & C++ IDE for Windows
Brought to you by:
claplace
|
From: Santiago <sa...@ho...> - 2002-10-13 20:38:50
|
Hi Elizabeth, thank you for helping me out. I still need your help creating the .o file with DevC++ and after I have created that file, can you explain what you mean by keywords "Object Files" and where to configure that. I could only find: "Linker options/Optional Libs or Object Files" Thanks again ----- Original Message ----- From: "Elizabeth Barham" <sog...@ya...> To: "Santiago" <sa...@ho...> Cc: "dev-cpp-users-list" <dev...@li...> Sent: Sunday, October 13, 2002 3:41 PM Subject: Re: [Dev-C++] implementation .o procedure > "Santiago" <sa...@ho...> writes: > > > Hi, I only have DevC++, I don't know if it's possible to use the commands > > gcc -c a.c and gcc -c b.c in DevC++. Anyway I'm still stuck with the first > > part of the process, creating a .o object file out of the implementation of > > a class I made. These are my questions again: > > 1- How do I create an object file using the implementation I created? I want > > someone else to use this object file so I don't have to give them my > > implementation code. > > 2- Once the object file is created, how does the user use it to compile > > his/her own client code? how does the user refer to the file in his/her > > client code by using #include "myClass.h", or "myClass.o", or both, or some > > other way? > > > > I'll play class creator and main creator(user) myself using DevC++ for > > testing purposes. > > > > I'll appreciate your help! > > Normally, to do such a thing, one makes a library, which is simply a > collection of .o files. On Win32, people tend to make DLL's, which are > libraries that are linked in at run-time. > > But, anyway, just pass the .o file (the object file) to the linker > when linking the library or executable. I explained the "menu steps" > in the last message. > > > Project > Project Options > > > > dialog and placing "myClass.o" in the field labeled, "Linker > > options/Optional Libs or Object Files" - the key words being "Object > > Files" in this case (files that have the .o extension). > > Elizabeth > |