views:

101

answers:

3

I'm unable to do a scenario from subject.

I have DirectX 9 March 2009 SDK installed, which is 9, "sub"-version c, but "sub-sub"-version is 41, so libs (d3dx9.lib d3d9.lib) are linking exports to dxd3d_41.dll.

What happens when I try to run my app on machine which has DX9.0c but not redistributable from march 2009 is now obvious :), it fails because it cannot find dxd3d_41.dll.

Which is standard solution for this problem? How Am I supposed to compile my app to be supported by all machines having DX 9.0c? Is that even achievable?

Thanx

+1  A: 

You need to install the runtime that matches the SDK you use to compile.

The only way to force this to work on ALL machines with DirectX9c installed is to use an old SDK (the first 9.0c SDK). However, I strongly recommend avoiding this. You are much better off just using March 09, and install the March runtimes along with your application installation.

Reed Copsey
A: 

The rules are that if you link to d3dx9 then you are expected to handle making sure that the required redist runtime components are installed.

Have a look at the page 'DirectX Installation for Game Developers' in the DXSDK docs.

Mr J
+1  A: 

The simplest solution is to link to the Microsoft DirectX end-user runtime updater on your download page and tell people to run this first to make sure that the runtime components are up to date before installing your application.

After that, the next simplest thing is to bundle the necessary runtime updater with your application and have users run it before running your installer.

All of this is documented in the SDK documentation.

legalize