From 07a52d1c61ca6368fe32e9ee7eb06e6eea8d200b Mon Sep 17 00:00:00 2001 From: Jonathan Dowland Date: Sat, 29 Aug 2015 10:16:33 +0100 Subject: Adjust PACKEDATTR for Clang Clang defines __GNUC__ but does not support the gnustruct packing attribute, so add some extra #ifdef checks to catch Clang. --- src/doomtype.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src') diff --git a/src/doomtype.h b/src/doomtype.h index 5377c8ca..bf0a40e3 100644 --- a/src/doomtype.h +++ b/src/doomtype.h @@ -51,7 +51,13 @@ // #ifdef __GNUC__ + +#ifdef __clang__ +#define PACKEDATTR __attribute__((packed)) +#else #define PACKEDATTR __attribute__((packed,gcc_struct)) +#endif + #else #define PACKEDATTR #endif -- cgit v1.2.3