If you're talking about XP->Win7, the last one that will work even with N64 emulators is DirectX9.0c June 2010 redistributable.
I did this a few weeks ago for Windows 98/2000. The last working versions for them are still up on their servers. But I had to really search for them on download.microsoft.com ...
I did it, and it installed XAudio2 and now Snes9x 1.53 works. I was using the wrong installer originally, then I found a softpedia download and it works.
However I tried using Direct3D on Snes9x (default display) and it didn't work, so I switched to OpenGL. However the required DLLs are now installed.
(see: Microsoft security essentials - for the full conversation)