diff mbox series

[v3,3/6] app/testpmd: add required Macros

Message ID 1618334363-15147-4-git-send-email-jizh@linux.microsoft.com (mailing list archive)
State Superseded, archived
Delegated to: Ferruh Yigit
Headers show
Series app/testpmd: enable testpmd on Windows | expand

Checks

Context Check Description
ci/checkpatch warning coding style issues

Commit Message

Jie Zhou April 13, 2021, 5:19 p.m. UTC
Signed-off-by: Jie Zhou <jizh@microsoft.com>
Signed-off-by: Jie Zhou <jizh@linux.microsoft.com>
---
 lib/librte_eal/windows/include/rte_os.h | 8 ++++++++
 1 file changed, 8 insertions(+)
diff mbox series

Patch

diff --git a/lib/librte_eal/windows/include/rte_os.h b/lib/librte_eal/windows/include/rte_os.h
index f0512f20a..60a623d4c 100644
--- a/lib/librte_eal/windows/include/rte_os.h
+++ b/lib/librte_eal/windows/include/rte_os.h
@@ -61,6 +61,14 @@  extern "C" {
 #define unlink _unlink
 #endif
 
+#define strcasecmp _stricmp
+#define open _open
+#define read _read
+
+#ifndef S_ISREG
+#define S_ISREG(mode)  (((mode)&S_IFMT) == S_IFREG)
+#endif
+
 /* cpu_set macros implementation */
 #define RTE_CPU_AND(dst, src1, src2) CPU_AND(dst, src1, src2)
 #define RTE_CPU_OR(dst, src1, src2) CPU_OR(dst, src1, src2)