Commit 0efe516e by Jamie Madill Committed by Commit Bot

Fix egl.h compatiblity.

We should include logic for defining EGL prototypes when no other preference is specified. Bug: angleproject:3706 Change-Id: Ie1b5ea6150c7c998a9fe71cf5ee7353dca4ae7ba Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1706908 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: 's avatarGeoff Lang <geofflang@chromium.org>
parent 96c696db
...@@ -6,9 +6,18 @@ The EGL headers ANGLE uses are generated using the Khronos tools but modified to ...@@ -6,9 +6,18 @@ The EGL headers ANGLE uses are generated using the Khronos tools but modified to
1. Install **Python 3** (not 2) with the **lxml** addon. You can do this using `pip install lxml` from your Python's Scripts folder. 1. Install **Python 3** (not 2) with the **lxml** addon. You can do this using `pip install lxml` from your Python's Scripts folder.
1. Clone [https://github.com/KhronosGroup/EGL-Registry.git](https://github.com/KhronosGroup/EGL-Registry.git). 1. Clone [https://github.com/KhronosGroup/EGL-Registry.git](https://github.com/KhronosGroup/EGL-Registry.git).
1. Edit `EGL-Registry/api/genheaders.py`: 1. Edit `EGL-Registry/api/genheaders.py` and add the following under `glesProtoPrefixStrings`:
```# EGL headers use a protection mechanism similar to GLES.
eglProtoPrefixStrings = [
'#ifndef EGL_EGL_PROTOTYPES',
'#define EGL_EGL_PROTOTYPES 1',
'#endif',
''
]
```
4. Also in `EGL-Registry/api/genheaders.py`:
1. Look for the section titled `# EGL API - EGL/egl.h (no function pointers, yet @@@)` 1. Look for the section titled `# EGL API - EGL/egl.h (no function pointers, yet @@@)`
1. Set `prefixText` to `prefixStrings + eglPlatformStrings + eglProtoPrefixStrings + genDateCommentString`
1. Change `genFuncPointers = False,` to `genFuncPointers = True,` 1. Change `genFuncPointers = False,` to `genFuncPointers = True,`
1. Change `protectProto = False,` to `protectProto = 'nonzero',` 1. Change `protectProto = False,` to `protectProto = 'nonzero',`
1. Change `protectProtoStr = 'EGL_EGLEXT_PROTOTYPES',` to `protectProtoStr = 'EGL_EGL_PROTOTYPES',` 1. Change `protectProtoStr = 'EGL_EGLEXT_PROTOTYPES',` to `protectProtoStr = 'EGL_EGL_PROTOTYPES',`
......
...@@ -33,12 +33,16 @@ extern "C" { ...@@ -33,12 +33,16 @@ extern "C" {
** used to make the header, and the header can be found at ** used to make the header, and the header can be found at
** http://www.khronos.org/registry/egl ** http://www.khronos.org/registry/egl
** **
** Khronos $Git commit SHA1: 4136522c4d $ on $Git commit date: 2018-12-06 03:51:22 -0800 $ ** Khronos $Git commit SHA1: d738c39fe2 $ on $Git commit date: 2019-06-14 16:17:31 -0600 $
*/ */
#include <EGL/eglplatform.h> #include <EGL/eglplatform.h>
/* Generated on date 20181214 */ #ifndef EGL_EGL_PROTOTYPES
#define EGL_EGL_PROTOTYPES 1
#endif
/* Generated on date 20190716 */
/* Generated C header for: /* Generated C header for:
* API: egl * API: egl
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment