From ab028964bffcdedf729a3568fd24518017f2bfc2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=8E=E9=80=9A=E6=B4=B2?= Date: Tue, 2 Jan 2024 18:47:06 +0800 Subject: [PATCH] GPU (WSL): add missing `FF_USE_PROPRIETARY_GPU_DRIVER_API` macro guards --- src/detection/gpu/gpu_wsl.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/detection/gpu/gpu_wsl.cpp b/src/detection/gpu/gpu_wsl.cpp index a847a53ec..91d67e54a 100644 --- a/src/detection/gpu/gpu_wsl.cpp +++ b/src/detection/gpu/gpu_wsl.cpp @@ -98,6 +98,7 @@ const char* ffGPUDetectByDirectX(FF_MAYBE_UNUSED const FFGPUOptions* options, FF const char* vendorStr = ffGetGPUVendorString((unsigned) hardwareId.vendorID); ffStrbufSetStatic(&gpu->vendor, vendorStr); + #ifdef FF_USE_PROPRIETARY_GPU_DRIVER_API if (vendorStr == FF_GPU_VENDOR_NAME_NVIDIA && (options->driverSpecific || options->temp)) { FFGpuDriverCondition cond = { @@ -117,6 +118,7 @@ const char* ffGPUDetectByDirectX(FF_MAYBE_UNUSED const FFGPUOptions* options, FF .frequency = &gpu->frequency, }, "/usr/lib/wsl/lib/libnvidia-ml.so"); } + #endif } }