diff --git a/plugins/snappy/snappy-stubs-public.h.in b/plugins/snappy/snappy-stubs-public.h.in index fa22d54..08ebbcb 100644 --- a/plugins/snappy/snappy-stubs-public.h.in +++ b/plugins/snappy/snappy-stubs-public.h.in @@ -58,6 +58,19 @@ #define SNAPPY_VERSION \ ((SNAPPY_MAJOR << 16) | (SNAPPY_MINOR << 8) | SNAPPY_PATCHLEVEL) +#if !defined(_WIN32) +# if !defined(BYTE_ORDER) +# include +# elif defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__bsdi__) || defined(__DragonFly__) +# include +# else +# include +# endif +# if defined(BYTE_ORDER) && (BYTE_ORDER == BIG_ENDIAN) +# define WORDS_BIGENDIAN +# endif +#endif + #include namespace snappy {