nvk: silence error when cross-building for Android

When cross-building NVK for Android the compiler emits this error:

-----------------------------------------------------------------------
../src/nouveau/vulkan/nvk_image.c:1084:38: error: unused variable 'pdev' [-Werror,-Wunused-variable]
 1084 |    const struct nvk_physical_device *pdev = nvk_device_physical(dev);
      |                                      ^~~~
1 error generated.
-----------------------------------------------------------------------

Mark the variable definition as UNUSED to silence the error.

Acked-by: Valentine Burley <valentine.burley@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36710>
This commit is contained in:
Antonio Ospite 2025-08-11 11:35:50 +02:00 committed by Marge Bot
parent 5ae3343590
commit 1dd1995388

View file

@ -1081,7 +1081,7 @@ nvk_CreateImage(VkDevice _device,
VkImage *pImage)
{
VK_FROM_HANDLE(nvk_device, dev, _device);
const struct nvk_physical_device *pdev = nvk_device_physical(dev);
UNUSED const struct nvk_physical_device *pdev = nvk_device_physical(dev);
struct nvk_image *image;
VkResult result;