Sign in to follow this  
Mulligan

I give up, here comes a DX linker error question

Recommended Posts

Im attempting to use the debugging macro V(x) from dxstdafx.h, and I cant find the right library to link to. Ive gone so far as to link every single .lib file in the DX April 2006 ./lib directory. The actual message: Error 1 error LNK2019: unresolved external symbol "long __stdcall DXUTTrace(char const *,unsigned long,long,wchar_t const *,bool)" (?DXUTTrace@@YGJPBDKJPB_W_N@Z) referenced in function "public: virtual long __thiscall EnigmaEngine::CSound2D::Play(void)" (?Play@CSound2D@EnigmaEngine@@UAEJXZ) Sound2D.obj Any help would be great, thanks

Share this post


Link to post
Share on other sites
Have no fear, Mulligan, I is here. ;)

The DXUT is designed to be a configurable library. Specifically, you can choose whether you want to link with just the core components, or some of the additional components that come with it. For this reason, Microsoft provides the DXUT "library" as a buildable project. If you look in:

C:\Program Files\Microsoft DirectX SDK (April 2006)\Samples\C++\Common

or your equivalent path, you'll find a project for "DXUT.lib." This project contains the "complete" DXUT library. If you look in:

C:\Program Files\Microsoft DirectX SDK (April 2006)\Samples\C++\DXUT

You'll find two subdirectories: "Core" and "Optional" which also contains projects/solutions divided up by components.

So you just pick the build you want to work with, compile/link the library, and then you'll have a library to link against.

Alternatively, you can just copy the contents of one of those directories, minus the .proj and .sln files into your local directory and then compile them into your local project. The benefits of doing it this way is that you can modify the library files without worrying about messing up your DirectX distribution.

Cheers!

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this