Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / Linker Error using DLLs

Author
Message
Amnzero
15
Years of Service
User Offline
Joined: 1st Aug 2009
Location:
Posted: 4th Feb 2010 08:08
Error 1 error LNK2019: unresolved external symbol "unsigned long __cdecl dbCallDLL(int,unsigned long)" (?dbCallDLL@@YAKHK@Z) referenced in function "public: void __thiscall DllObj::Call(char *)" (?Call@DllObj@@QAEXPAD@Z) DllObj.obj
Error 2 error LNK2019: unresolved external symbol "unsigned long __cdecl dbCallDLLX(int,unsigned long,unsigned long,unsigned long)" (?dbCallDLLX@@YAKHKKK@Z) referenced in function "public: unsigned long __thiscall DllObj::Call(char *,char *,int)" (?Call@DllObj@@QAEKPAD0H@Z) DllObj.obj
Error 3 error LNK2019: unresolved external symbol "int __cdecl dbDLLCallExist(int,unsigned long)" (?dbDLLCallExist@@YAHHK@Z) referenced in function "public: int __thiscall DllObj::CallExists(char *)" (?CallExists@DllObj@@QAEHPAD@Z) DllObj.obj
Error 4 fatal error LNK1120: 3 unresolved externals

Im not sure if this is due to the way I am defining these functions or if there is an issue somewhere else, that I am not seeing. Let me know if you have any light to shed on this.

DllObj.h


DllObj.cpp


if(enemy == Amnzero) runAway();
Amnzero->WebSite = L"http://neovance.com/";
bloodmage2
15
Years of Service
User Offline
Joined: 14th Jun 2009
Location:
Posted: 4th Feb 2010 17:55
this is saying that something is declared like:
class testClass {
void testFunction(int testParameter);
}

but never defined like:

void testClass::testFunction(int testParameter) {
//code
}

make sure all libaries are included with #include 's and in the project properties menu -> library and include directories dialog.

-to the optimist, the glass is half full. to the pessimist, it is half empty, to the engineer, it is twice as big as it needs to be.
Bran flakes91093
16
Years of Service
User Offline
Joined: 13th Sep 2008
Location: Crazy Land
Posted: 4th Feb 2010 21:25
Put

#include "DllObj.h"

in DllObj.cpp

Your_Health = (My_Mood == HAPPY) ? 100 : NULL;
Amnzero
15
Years of Service
User Offline
Joined: 1st Aug 2009
Location:
Posted: 6th Feb 2010 01:10
Quote: "#include "DllObj.h""


Yes. I only gave you the lines from the files that I was getting the errors from. This is included already.

Quote: "make sure all libaries are included with #include 's and in the project properties menu -> library and include directories dialog."


Well I was assuming that all of that was included when I included DarkGDK.h, which is why I don't understand the problem I am having here, since clearly the functions are declared, and defined. I dunno. I am not even sure where to start on this one. All I can think is that the functions i am trying to wrap need to be user defined, and are only declared by the GDK? I dunno, I have never used these functions before. I am just trying to wrap all the GDK functions into a class library.

if(enemy == Amnzero) runAway();
Amnzero->WebSite = L"http://neovance.com/";
Caleb1994
16
Years of Service
User Offline
Joined: 10th Oct 2008
Location: The Internet you idiot!
Posted: 7th Feb 2010 04:05 Edited at: 7th Feb 2010 04:07
Are you including DarkGDK.h in DllObj.cpp?

Quote: "libaries are included with #include 's"


I think you mean "Headers are included with #includes's" and it's only one header. DarkGDK.h

New Site! Check it out \/
Amnzero
15
Years of Service
User Offline
Joined: 1st Aug 2009
Location:
Posted: 7th Feb 2010 15:29
Quote: ""Headers are included with #includes's""


I beleive its #includes'

Quote: "Are you including DarkGDK.h in DllObj.cpp?"


Im including it it DllObj.h which should be included in DllObj.cpp by proxy right? I mean it has not given me a problem with any of the other DGDK functions yet. Just these three.

if(enemy == Amnzero) runAway();
Amnzero->WebSite = L"http://neovance.com/";

Login to post a reply

Server time is: 2024-11-20 05:23:01
Your offset time is: 2024-11-20 05:23:01