Some glad improvements
- Silence a MSVC warning in vulkan.cpp, refs #6987 - Document the patching of gl.h for macOS, from r26094 - Fix shellcheck warnings in the generation script
This commit is contained in:
parent
35d998694f
commit
0f87124b98
@ -959,6 +959,10 @@ function setup_all_libs ()
|
|||||||
files { glad_path.."src/egl.cpp", glad_path.."src/glx.cpp" }
|
files { glad_path.."src/egl.cpp", glad_path.."src/glx.cpp" }
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
-- on Windows, silence a build warning in vulkan.cpp
|
||||||
|
filter "action:vs*"
|
||||||
|
buildoptions { "/wd4551" }
|
||||||
|
filter {}
|
||||||
|
|
||||||
|
|
||||||
-- Third-party libraries that are built as part of the main project,
|
-- Third-party libraries that are built as part of the main project,
|
||||||
|
3
source/third_party/glad/README.md
vendored
3
source/third_party/glad/README.md
vendored
@ -15,6 +15,9 @@ cd glad
|
|||||||
pip install -r requirements.txt
|
pip install -r requirements.txt
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Do not revert the WFG patch in include/glad/gl.h (around line 1765):
|
||||||
|
do not add the change reverting it after the generation of the file
|
||||||
|
|
||||||
Build the source files for all four backends with their respective extensions
|
Build the source files for all four backends with their respective extensions
|
||||||
- GL
|
- GL
|
||||||
```sh
|
```sh
|
||||||
|
1
source/third_party/glad/include/glad/gl.h
vendored
1
source/third_party/glad/include/glad/gl.h
vendored
@ -1763,6 +1763,7 @@ typedef void *GLeglImageOES;
|
|||||||
typedef char GLchar;
|
typedef char GLchar;
|
||||||
typedef char GLcharARB;
|
typedef char GLcharARB;
|
||||||
#ifdef __APPLE__
|
#ifdef __APPLE__
|
||||||
|
// --- Patched by WFG
|
||||||
// See https://bugs.freedesktop.org/show_bug.cgi?id=66346
|
// See https://bugs.freedesktop.org/show_bug.cgi?id=66346
|
||||||
// macOS considers those to be different.
|
// macOS considers those to be different.
|
||||||
// typedef void *GLhandleARB;
|
// typedef void *GLhandleARB;
|
||||||
|
17
source/third_party/glad/update-headers.sh
vendored
17
source/third_party/glad/update-headers.sh
vendored
@ -1,12 +1,13 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
cd glad
|
(
|
||||||
python -m glad --api="gl:core=2.1" --extensions="../extensions/gl.txt" --out-path="../" c
|
cd glad || exit
|
||||||
python -m glad --api="gles2=2.0" --extensions="../extensions/gles2.txt" --out-path="../" c
|
python -m glad --api="gl:core=2.1" --extensions="../extensions/gl.txt" --out-path="../" c
|
||||||
python -m glad --api="glx=1.4" --extensions="../extensions/glx.txt" --out-path="../" c
|
python -m glad --api="gles2=2.0" --extensions="../extensions/gles2.txt" --out-path="../" c
|
||||||
python -m glad --api="wgl=1.0" --extensions="../extensions/wgl.txt" --out-path="../" c
|
python -m glad --api="glx=1.4" --extensions="../extensions/glx.txt" --out-path="../" c
|
||||||
python -m glad --api="egl=1.5" --extensions="../extensions/egl.txt" --out-path="../" c
|
python -m glad --api="wgl=1.0" --extensions="../extensions/wgl.txt" --out-path="../" c
|
||||||
python -m glad --api="vulkan=1.1" --extensions="../extensions/vulkan.txt" --out-path="../" c
|
python -m glad --api="egl=1.5" --extensions="../extensions/egl.txt" --out-path="../" c
|
||||||
cd ..
|
python -m glad --api="vulkan=1.1" --extensions="../extensions/vulkan.txt" --out-path="../" c
|
||||||
|
)
|
||||||
mv src/gl.c src/gl.cpp
|
mv src/gl.c src/gl.cpp
|
||||||
mv src/gles2.c src/gles2.cpp
|
mv src/gles2.c src/gles2.cpp
|
||||||
mv src/glx.c src/glx.cpp
|
mv src/glx.c src/glx.cpp
|
||||||
|
Loading…
Reference in New Issue
Block a user