Skip to content

Commit d9f66be

Browse files
committed
bus/pci: fix build with MinGW 13
After an upgrade to MinGW version 13, some compilation errors appear: drivers/bus/pci/windows/pci.c:362:58: error: 'GUID_DEVCLASS_NETUIO' undeclared drivers/bus/pci/windows/pci_netuio.c:57:39: error: 'GUID_DEVINTERFACE_NETUIO' undeclared The cause is MinGW has set NTDDI_VERSION to the highest version without defining the expected NETUIO constants. It is safer to not rely on Windows headers version, and instead define what is not already defined. Fixes: 6605c7f ("bus/pci: fix build with Windows SDK >= 10.0.20253") Cc: [email protected] Signed-off-by: Thomas Monjalon <[email protected]> Acked-by: Bruce Richardson <[email protected]>
1 parent 00092e9 commit d9f66be

File tree

2 files changed

+3
-7
lines changed

2 files changed

+3
-7
lines changed

drivers/bus/pci/windows/pci_netuio.c

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,6 @@
1010
#include <rte_eal.h>
1111
#include <rte_bus_pci.h>
1212

13-
#ifdef __MINGW32__
14-
#include <ddk/ndisguid.h>
15-
#else
16-
#include <ndisguid.h>
17-
#endif
18-
1913
#include "private.h"
2014
#include "pci_netuio.h"
2115

drivers/bus/pci/windows/pci_netuio.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,13 @@
55
#ifndef _PCI_NETUIO_H_
66
#define _PCI_NETUIO_H_
77

8-
#if !defined(NTDDI_WIN10_FE) || NTDDI_VERSION < NTDDI_WIN10_FE
8+
#ifndef GUID_DEVCLASS_NETUIO
99
/* GUID definition for device class netUIO */
1010
DEFINE_GUID(GUID_DEVCLASS_NETUIO, 0x78912bc1, 0xcb8e, 0x4b28,
1111
0xa3, 0x29, 0xf3, 0x22, 0xeb, 0xad, 0xbe, 0x0f);
12+
#endif
1213

14+
#ifndef GUID_DEVINTERFACE_NETUIO
1315
/* GUID definition for the netuio device interface */
1416
DEFINE_GUID(GUID_DEVINTERFACE_NETUIO, 0x08336f60, 0x0679, 0x4c6c,
1517
0x85, 0xd2, 0xae, 0x7c, 0xed, 0x65, 0xff, 0xf7);

0 commit comments

Comments
 (0)