diff options
author | Michael Brown <mcb30@etherboot.org> | 2009-03-10 17:50:01 +0000 |
---|---|---|
committer | Michael Brown <mcb30@etherboot.org> | 2009-03-26 07:27:19 +0000 |
commit | 1c67623e37dada045e9b5d1f5e19b414cc79c3e3 (patch) | |
tree | 6baaac3371a85232dbfe0faa5e7530eb76fa7413 /src/include/gpxe/efi | |
parent | 16aa435567ad6a82669864ba9c47ee534a03c296 (diff) | |
download | ipxe-1c67623e37dada045e9b5d1f5e19b414cc79c3e3.tar.gz |
[build] Enable building with the Intel C compiler (icc)
Diffstat (limited to 'src/include/gpxe/efi')
-rw-r--r-- | src/include/gpxe/efi/efi.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/include/gpxe/efi/efi.h b/src/include/gpxe/efi/efi.h index 1f5b88563..a71a29e27 100644 --- a/src/include/gpxe/efi/efi.h +++ b/src/include/gpxe/efi/efi.h @@ -31,6 +31,11 @@ /* EFI headers rudely redefine NULL */ #undef NULL +/* EFI headers expect ICC to define __GNUC__ */ +#if defined ( __ICC ) && ! defined ( __GNUC__ ) +#define __GNUC__ 1 +#endif + /* Include the top-level EFI header files */ #include <gpxe/efi/Uefi.h> #include <gpxe/efi/PiDxe.h> @@ -69,7 +74,7 @@ struct efi_protocol { struct efi_protocol __ ## _protocol __efi_protocol = { \ .u.guid = _protocol ## _GUID, \ .protocol = ( ( void ** ) ( void * ) \ - ( ( (_ptr) == ( ( _protocol ** ) NULL ) ) ? \ + ( ( (_ptr) == ( ( _protocol ** ) (_ptr) ) ) ? \ (_ptr) : (_ptr) ) ), \ } |