Home | History | Annotate | Line # | Download | only in inc
      1  1.2  jmcneill /*	$NetBSD: eficompiler.h,v 1.2 2018/08/16 18:24:35 jmcneill Exp $	*/
      2  1.1  jmcneill 
      3  1.1  jmcneill /*++
      4  1.1  jmcneill 
      5  1.1  jmcneill Copyright (c) 2016 Pete Batard <pete (at) akeo.ie>
      6  1.1  jmcneill 
      7  1.1  jmcneill Module Name:
      8  1.1  jmcneill 
      9  1.1  jmcneill     eficompiler.h
     10  1.1  jmcneill 
     11  1.1  jmcneill Abstract:
     12  1.1  jmcneill 
     13  1.1  jmcneill     Compiler specific adjustments
     14  1.1  jmcneill 
     15  1.1  jmcneill --*/
     16  1.1  jmcneill 
     17  1.1  jmcneill #ifdef _MSC_EXTENSIONS
     18  1.1  jmcneill #define EFI_UNUSED
     19  1.1  jmcneill #else
     20  1.1  jmcneill #define EFI_UNUSED __attribute__((__unused__))
     21  1.1  jmcneill #endif
     22  1.1  jmcneill 
     23  1.1  jmcneill #ifdef _MSC_EXTENSIONS
     24  1.2  jmcneill #define EFI_ALIGN(x) __declspec(align(x))
     25  1.1  jmcneill #else
     26  1.2  jmcneill #define EFI_ALIGN(x) __attribute__((__aligned__(x)))
     27  1.1  jmcneill #endif
     28  1.1  jmcneill 
     29  1.1  jmcneill /* Also add a catch-all on __attribute__() for MS compilers */
     30  1.1  jmcneill #ifdef _MSC_EXTENSIONS
     31  1.1  jmcneill #define __attribute__(x)
     32  1.1  jmcneill #endif
     33