d3d build fixes