diff --git a/src/frontend-common/d3d11_host_display.cpp b/src/frontend-common/d3d11_host_display.cpp index 8753995a3..e8ea92a51 100644 --- a/src/frontend-common/d3d11_host_display.cpp +++ b/src/frontend-common/d3d11_host_display.cpp @@ -6,7 +6,9 @@ #include "display_ps.hlsl.h" #include "display_vs.hlsl.h" #include +#if defined(__has_include) && __has_include() #include +#endif #include #include Log_SetChannel(D3D11HostDisplay); @@ -258,6 +260,7 @@ bool D3D11HostDisplay::CreateRenderDevice(const WindowInfo& wi, std::string_view } m_allow_tearing_supported = false; +#if defined(__has_include) && __has_include() ComPtr dxgi_factory5; hr = m_dxgi_factory.As(&dxgi_factory5); if (SUCCEEDED(hr)) @@ -268,6 +271,7 @@ bool D3D11HostDisplay::CreateRenderDevice(const WindowInfo& wi, std::string_view if (SUCCEEDED(hr)) m_allow_tearing_supported = (allow_tearing_supported == TRUE); } +#endif m_window_info = wi; return true;