Advertisement

Why unresolved externals? (C++)

Started by October 05, 2017 01:23 PM
3 comments, last by Capoeirista 7 years, 2 months ago

I cannot compile my game anymore. It only happens in release build, not debug and I cannot figure it out.

I have cleaned and recompiled the project. The function in question is only mensioned in three lines:


  C:\Dropbox\PROJECT\code\epaengine\gameController.cpp(15):bool gameController::CheckConnection(std::vector<bool> & occupiedPorts)
  C:\Dropbox\PROJECT\code\epaengine\gameController.cpp(40):		CheckConnection(occupiedPorts);
  C:\Dropbox\PROJECT\code\epaengine\gameController.h(46):	bool CheckConnection(std::vector<bool> & occupiedPorts);
  Matching lines: 3    Matching files: 2    Total files searched: 59

 

This is the build error:


Error	3	error LNK2019: unresolved external symbol _XInputGetState@8 referenced in function "public: bool __thiscall gameController::CheckConnection(class std::vector<bool,class std::allocator<bool> > &)" (?CheckConnection@gameController@@QAE_NAAV?$vector@_NV?$allocator@_N@std@@@std@@@Z)	C:\Dropbox\PROJECT\code\games\post\source\gameController.obj	zombies

What can be wrong here?
Thank you

Erik

Are you linking to the XInput lib in your release build?

Advertisement

Yay!

The release-build had an old path in "additional dependencies". Now it works fine!

Thanks capoeira-ninja-coder!
Erik

Hah ha, no trouble :)

This topic is closed to new replies.

Advertisement