Zebediah Figura (@zfigura) commented about tests/dxcompiler.idl:
+/* The linux build of dxcompiler does not apply the ms_abi calling convention to its COM interfaces,
- so they default to sysv_abi. The '__stdcall' macro is set in vkd3d_windows.h to ms_abi, and widl
- emits STDMETHODCALLTYPE for COM interfaces, so '__stdcall' must be temporarily undefined. Doing
- this in a PE build (x86 or x64) is unnecessary since the default calling convention is identical.
- A 32-bit linux release of dxcompiler is not available.
- TODO: modily widl to optionally omit STDMETHODCALLTYPE? */
+cpp_quote("#if defined(__x86_64__) && !defined(_WIN32)") +cpp_quote("# pragma push_macro("__stdcall")") +cpp_quote("# undef __stdcall") +cpp_quote("# define __stdcall") +cpp_quote("#endif")
+static const HRESULT DXC_E_LLVM_CAST_ERROR = 0x80aa001d;
+cpp_quote("DEFINE_GUID(CLSID_DxcCompiler, 0x73e22d93, 0xe6ce, 0x47f3, 0xb5, 0xbf, 0xf0, 0x66, 0x4f, 0x39, 0xc1, 0xb0);")
This is an IDL, so we can do this with a "coclass" block.