diff options
| author | Michael Brown | 2009-03-10 18:50:01 +0100 |
|---|---|---|
| committer | Michael Brown | 2009-03-26 08:27:19 +0100 |
| commit | 1c67623e37dada045e9b5d1f5e19b414cc79c3e3 (patch) | |
| tree | 6baaac3371a85232dbfe0faa5e7530eb76fa7413 /src/include/gpxe/efi/efi.h | |
| parent | [3c90x] Remove src/drivers/3c90x.txt (diff) | |
| download | ipxe-1c67623e37dada045e9b5d1f5e19b414cc79c3e3.tar.gz ipxe-1c67623e37dada045e9b5d1f5e19b414cc79c3e3.tar.xz ipxe-1c67623e37dada045e9b5d1f5e19b414cc79c3e3.zip | |
[build] Enable building with the Intel C compiler (icc)
Diffstat (limited to 'src/include/gpxe/efi/efi.h')
| -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) ) ), \ } |
