From e286fe869aa5d85feca4bc51692573b7a37a2468 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vedran=20Mileti=C4=87?= Date: Sun, 24 May 2020 18:00:00 +0200 Subject: [PATCH] Fix building of ORM on FreeBSD (#444) --- orm_lib/inc/drogon/orm/SqlBinder.h | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/orm_lib/inc/drogon/orm/SqlBinder.h b/orm_lib/inc/drogon/orm/SqlBinder.h index 67e7c8b0..dbee0d44 100644 --- a/orm_lib/inc/drogon/orm/SqlBinder.h +++ b/orm_lib/inc/drogon/orm/SqlBinder.h @@ -31,10 +31,20 @@ #include #ifdef _WIN32 #include +#else // some Unix-like OS +#include #endif +#if defined __linux__ || defined __FreeBSD__ + #ifdef __linux__ -#include // __BYTE_ORDER __LITTLE_ENDIAN +#include // __BYTE_ORDER __LITTLE_ENDIAN +#elif defined __FreeBSD__ +#include // _BYTE_ORDER _LITTLE_ENDIAN +#define __BYTE_ORDER _BYTE_ORDER +#define __LITTLE_ENDIAN _LITTLE_ENDIAN +#endif + #include // std::reverse() template