Archived

This topic is now archived and is closed to further replies.

Newbie problem with libraries

This topic is 4955 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

Hi Sory for stupid question but it is important for me. Here are libraries which I include to my project dinput.lib dinput8.lib d3dx9.lib d3d9.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib And here goes compiler error. d3dfile.obj : error LNK2001: unresolved external symbol _D3DXLoadMeshFromX@28 d3dXModel.obj : error LNK2001: unresolved external symbol _D3DXLoadMeshFromX@28 d3dfile.obj : error LNK2001: unresolved external symbol _D3DXLoadMeshFromXof@28 d3dfile.obj : error LNK2001: unresolved external symbol _TID_D3DRMFrame d3dfile.obj : error LNK2001: unresolved external symbol _TID_D3DRMFrameTransformMatrix d3dfile.obj : error LNK2001: unresolved external symbol _TID_D3DRMMesh d3dfile.obj : error LNK2001: unresolved external symbol _DirectXFileCreate@4 d3dutil.obj : error LNK2001: unresolved external symbol _D3DXAssembleShaderFromFileA@20 dxutil.obj : error LNK2001: unresolved external symbol __imp__timeGetTime@0 GameApp.obj : error LNK2001: unresolved external symbol _GUID_SysKeyboard GameApp.obj : error LNK2001: unresolved external symbol _IID_IDirectInput8A GameApp.obj : error LNK2001: unresolved external symbol _Direct3DCreate8@4 dinput.lib(dilib2.obj) : error LNK2001: unresolved external symbol _GUID_Key LIBCD.lib(crt0.obj) : error LNK2001: unresolved external symbol _main Debug/kupa.exe : fatal error LNK1120: 13 unresolved externals And I really don''t know what is wrong Maybe the problem is that I include d3dx9 lib, because this project(not mine) was made in Directx 8??

Share this post


Link to post
Share on other sites
Looks like you may be mixing DirectX versions e.g. Direct3DCreate8 not 9? timeGetTime requires linking with winmm.lib. Your last warning is worrying : unresolved external _main - it seems to suggest you have a project set up as a console project (or something akin) when it should be a Windows project.,

Share this post


Link to post
Share on other sites
Creating something as a console project is not bad. You add perhaps one line of code compared to WinMain (you need the instance handle) and gain a much better way to debug your code (because you can simply output debug messages onto the console).

Share this post


Link to post
Share on other sites
BitMaster: I did not say it was bad to create a console app just that he is probably wanting to create a windows app hence the missing main.

Share this post


Link to post
Share on other sites
Thank you guys for Your help. When I included dxguid.lib the ammount of erros went down to 9. But I decided to give up this project(it isn''t mine, but I wanted to learn sth from it)

Thanks again for Your time.

Share this post


Link to post
Share on other sites