diff mbox series

[v2,1/3] eal: correct OS headers in rte_byteorder.h

Message ID 20200625152416.11368-2-talshn@mellanox.com (mailing list archive)
State Accepted, archived
Delegated to: Thomas Monjalon
Headers show
Series Support librte_mbuf on Windows | expand

Checks

Context Check Description
ci/Intel-compilation fail apply issues
ci/checkpatch success coding style OK

Commit Message

Tal Shnaiderman June 25, 2020, 3:24 p.m. UTC
From: Tal Shnaiderman <talshn@mellanox.com>

Inclusion of the endian.h header is set only for Linux OS.

Windows endlessness will be determined by the predefined
__BYTE_ORDER__ macro.

Signed-off-by: Tal Shnaiderman <talshn@mellanox.com>
---
 lib/librte_eal/include/generic/rte_byteorder.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/lib/librte_eal/include/generic/rte_byteorder.h b/lib/librte_eal/include/generic/rte_byteorder.h
index 9ca960932f..a67e1d70d9 100644
--- a/lib/librte_eal/include/generic/rte_byteorder.h
+++ b/lib/librte_eal/include/generic/rte_byteorder.h
@@ -17,7 +17,7 @@ 
 #include <stdint.h>
 #ifdef RTE_EXEC_ENV_FREEBSD
 #include <sys/endian.h>
-#else
+#elif defined RTE_EXEC_ENV_LINUX
 #include <endian.h>
 #endif