summaryrefslogtreecommitdiffstats
path: root/sys/amd64/include/efi.h
diff options
context:
space:
mode:
Diffstat (limited to 'sys/amd64/include/efi.h')
-rw-r--r--sys/amd64/include/efi.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/sys/amd64/include/efi.h b/sys/amd64/include/efi.h
index 272d5a8..a0a39b4 100644
--- a/sys/amd64/include/efi.h
+++ b/sys/amd64/include/efi.h
@@ -36,8 +36,14 @@
* XXX: from gcc 6.2 manual:
* Note, the ms_abi attribute for Microsoft Windows 64-bit targets
* currently requires the -maccumulate-outgoing-args option.
+ *
+ * Avoid EFIABI_ATTR declarations for compilers that don't support it.
+ * GCC support began in version 4.4.
*/
+#if defined(__clang__) || defined(__GNUC__) && \
+ (__GNUC__ > 4 || __GNUC__ == 4 && __GNUC_MINOR__ >= 4)
#define EFIABI_ATTR __attribute__((ms_abi))
+#endif
#ifdef _KERNEL
struct uuid;
OpenPOWER on IntegriCloud