• Advertisement
Sign in to follow this  

Linking Problems

This topic is 4172 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Ok so I'm using Jim Adams' Programming Role-Playing Games with DirectX. I've managed to fix most of the errors with the conversion from DX8 to DX9. The only one I have left now is: error C3861: 'DirectPlay8AddressCreate': identifier not found At this line... ... // Create address objects if(FAILED(CoCreateInstance(CLSID_DirectPlay8Address, NULL, CLSCTX_INPROC_SERVER, IID_IDirectPlay8Address, (void**) &pDPAddress))) return FALSE; if(FAILED(DirectPlay8AddressCreate(&IID_IDirectPlay8Address, (void**)&pDPDevice, NULL))){ return FALSE; pDPAddress->Release(); } // Set protocols ... When I try and change that to a CoCreateInstance() like I did with the one above it (which was previously a DirectPlay8AddressCreate) and compile I get the following errors. Also, even if I just remove the DirectPlay8AddressCreate altogether, I get these errors.
Linking...
core_graphics.obj : error LNK2019: unresolved external symbol _Direct3DCreate9@4 referenced in function "public: int __thiscall cGraphics::Init(void)" (?Init@cGraphics@@QAEHXZ)
core_graphics.obj : error LNK2019: unresolved external symbol _D3DXCreateSprite@8 referenced in function "public: int __thiscall cGraphics::SetMode(struct HWND__ *,int,int,long,long,char)" (?SetMode@cGraphics@@QAEHPAUHWND__@@HHJJD@Z)
core_graphics.obj : error LNK2019: unresolved external symbol _D3DXMatrixPerspectiveFovLH@20 referenced in function "public: int __thiscall cGraphics::SetPerspective(float,float,float,float)" (?SetPerspective@cGraphics@@QAEHMMMM@Z)
core_graphics.obj : error LNK2019: unresolved external symbol _D3DXMatrixTranslation@16 referenced in function "public: int __thiscall cWorldPosition::Move(float,float,float)" (?Move@cWorldPosition@@QAEHMMM@Z)
core_graphics.obj : error LNK2019: unresolved external symbol _D3DXMatrixRotationYawPitchRoll@16 referenced in function "public: int __thiscall cWorldPosition::Rotate(float,float,float)" (?Rotate@cWorldPosition@@QAEHMMM@Z)
core_graphics.obj : error LNK2019: unresolved external symbol _D3DXMatrixScaling@16 referenced in function "public: int __thiscall cWorldPosition::Scale(float,float,float)" (?Scale@cWorldPosition@@QAEHMMM@Z)
core_graphics.obj : error LNK2019: unresolved external symbol _D3DXMatrixMultiply@12 referenced in function "public: int __thiscall cWorldPosition::Update(class cGraphics *)" (?Update@cWorldPosition@@QAEHPAVcGraphics@@@Z)
core_graphics.obj : error LNK2019: unresolved external symbol _D3DXMatrixTranspose@8 referenced in function "public: int __thiscall cWorldPosition::Update(class cGraphics *)" (?Update@cWorldPosition@@QAEHPAVcGraphics@@@Z)
core_graphics.obj : error LNK2019: unresolved external symbol _D3DXMatrixRotationZ@8 referenced in function "public: int __thiscall cCamera::Rotate(float,float,float)" (?Rotate@cCamera@@QAEHMMM@Z)
core_graphics.obj : error LNK2019: unresolved external symbol _D3DXMatrixRotationY@8 referenced in function "public: int __thiscall cCamera::Rotate(float,float,float)" (?Rotate@cCamera@@QAEHMMM@Z)
core_graphics.obj : error LNK2019: unresolved external symbol _D3DXMatrixRotationX@8 referenced in function "public: int __thiscall cCamera::Rotate(float,float,float)" (?Rotate@cCamera@@QAEHMMM@Z)
core_graphics.obj : error LNK2019: unresolved external symbol _D3DXCreateFontIndirectA@12 referenced in function "public: int __thiscall cFont::Create(class cGraphics *,char *,long,int,int)" (?Create@cFont@@QAEHPAVcGraphics@@PADJHH@Z)
core_graphics.obj : error LNK2019: unresolved external symbol _D3DXCreateTextureFromFileExA@56 referenced in function "public: int __thiscall cTexture::Load(class cGraphics *,char *,unsigned long,enum _D3DFORMAT)" (?Load@cTexture@@QAEHPAVcGraphics@@PADKW4_D3DFORMAT@@@Z)
core_graphics.obj : error LNK2019: unresolved external symbol _D3DXGetFVFVertexSize@4 referenced in function "public: unsigned long __thiscall cVertexBuffer::GetVertexSize(void)" (?GetVertexSize@cVertexBuffer@@QAEKXZ)
core_input.obj : error LNK2019: unresolved external symbol _DirectInput8Create@20 referenced in function "public: int __thiscall cInput::Init(struct HWND__ *,struct HINSTANCE__ *)" (?Init@cInput@@QAEHPAUHWND__@@PAUHINSTANCE__@@@Z)
core_input.obj : error LNK2001: unresolved external symbol _IID_IDirectInput8A
core_input.obj : error LNK2001: unresolved external symbol _c_dfDIJoystick
core_input.obj : error LNK2001: unresolved external symbol _c_dfDIMouse
core_input.obj : error LNK2001: unresolved external symbol _GUID_SysMouse
core_input.obj : error LNK2001: unresolved external symbol _c_dfDIKeyboard
core_input.obj : error LNK2001: unresolved external symbol _GUID_SysKeyboard
core_network.obj : error LNK2001: unresolved external symbol _CLSID_DP8SP_TCPIP
core_network.obj : error LNK2001: unresolved external symbol _CLSID_DirectPlay8Client
core_network.obj : error LNK2001: unresolved external symbol _IID_IDirectPlay8Client
core_network.obj : error LNK2001: unresolved external symbol _CLSID_DirectPlay8Server
core_network.obj : error LNK2001: unresolved external symbol _IID_IDirectPlay8Server
core_network.obj : error LNK2001: unresolved external symbol _CLSID_DirectPlay8Address
core_network.obj : error LNK2001: unresolved external symbol _IID_IDirectPlay8Address
core_network.obj : error LNK2019: unresolved external symbol _inet_ntoa@4 referenced in function "public: int __thiscall cNetworkServer::GetIP(char *,unsigned long)" (?GetIP@cNetworkServer@@QAEHPADK@Z)
core_network.obj : error LNK2019: unresolved external symbol _WSACleanup@0 referenced in function "public: int __thiscall cNetworkServer::GetIP(char *,unsigned long)" (?GetIP@cNetworkServer@@QAEHPADK@Z)
core_network.obj : error LNK2019: unresolved external symbol _gethostbyname@4 referenced in function "public: int __thiscall cNetworkServer::GetIP(char *,unsigned long)" (?GetIP@cNetworkServer@@QAEHPADK@Z)
core_network.obj : error LNK2019: unresolved external symbol _gethostname@8 referenced in function "public: int __thiscall cNetworkServer::GetIP(char *,unsigned long)" (?GetIP@cNetworkServer@@QAEHPADK@Z)
core_network.obj : error LNK2019: unresolved external symbol _WSAStartup@8 referenced in function "public: int __thiscall cNetworkServer::GetIP(char *,unsigned long)" (?GetIP@cNetworkServer@@QAEHPADK@Z)
core_sound.obj : error LNK2001: unresolved external symbol _GUID_DirectMusicAllTypes
core_sound.obj : error LNK2001: unresolved external symbol _GUID_PerfMasterVolume
core_sound.obj : error LNK2001: unresolved external symbol _CLSID_DirectMusicPerformance
core_sound.obj : error LNK2001: unresolved external symbol _IID_IDirectMusicPerformance8
core_sound.obj : error LNK2001: unresolved external symbol _CLSID_DirectMusicLoader
core_sound.obj : error LNK2001: unresolved external symbol _IID_IDirectMusicLoader8
core_sound.obj : error LNK2019: unresolved external symbol _DirectSoundCreate8@12 referenced in function "public: int __thiscall cSound::Init(struct HWND__ *,long,short,short,long)" (?Init@cSound@@QAEHPAUHWND__@@JFFJ@Z)
core_sound.obj : error LNK2001: unresolved external symbol _IID_IDirectSoundNotify
core_sound.obj : error LNK2001: unresolved external symbol _IID_IDirectSoundBuffer8
core_sound.obj : error LNK2001: unresolved external symbol _GUID_StandardMIDIFile
core_sound.obj : error LNK2001: unresolved external symbol _IID_IDirectMusicSegment8
core_sound.obj : error LNK2001: unresolved external symbol _CLSID_DirectMusicSegment
core_sound.obj : error LNK2001: unresolved external symbol _GUID_ConnectToDLSCollection
core_sound.obj : error LNK2001: unresolved external symbol _GUID_PerfMasterTempo
core_sound.obj : error LNK2001: unresolved external symbol _IID_IDirectMusicCollection
core_sound.obj : error LNK2001: unresolved external symbol _GUID_DefaultGMCollection
core_sound.obj : error LNK2001: unresolved external symbol _CLSID_DirectMusicCollection
50 linking errors show up when I remove or change one line of code. Any ideas?

Share this post


Link to post
Share on other sites
Advertisement
Sign in to follow this  

  • Advertisement