linking lib file ...

S

szydel

Hi,
I need to use existing dll file, I've got mylib.dll, mylib.lib,
mylib.h files. All files are in the same directory, theres is #include
<mylib.h> directive in cpp file.
comilation:
g++ -c main.cpp
g++ -o main.exe -L . -lmylib main.o

all i get is undifined referene :(

There is an example runnig it in VC++ 6 but i dont have it(VC++6). I'm
trying to run in in DEV-C++. Is dev so much diffrent that its
impossible to do it.
thanks for replay.
 
M

mlimber

szydel said:
I need to use existing dll file, I've got mylib.dll, mylib.lib,
mylib.h files. All files are in the same directory, theres is #include
<mylib.h> directive in cpp file.
comilation:
g++ -c main.cpp
g++ -o main.exe -L . -lmylib main.o

all i get is undifined referene :(

There is an example runnig it in VC++ 6 but i dont have it(VC++6). I'm
trying to run in in DEV-C++. Is dev so much diffrent that its
impossible to do it.

This is a platform-specific question, not a C++ *language* question,
and it should be asked in a group for your platform or compiler. See
this FAQ for what is on-topic here and for a list of some other places
you might consider asking:

http://www.parashift.com/c++-faq-lite/how-to-post.html#faq-5.9

Cheers! --M
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,069
Latest member
SimplyleanKetoReviews

Latest Threads

Top