glad
Multi-Language Vulkan/GL/GLES/EGL/GLX/WGL Loader-Generator based on the official specs.
Latest version: 2.0.8
Add to xmake.lua
add_requires("glad 2.0.8")Learn how to add and link packages with Xmake →
Information
- License
- MIT
- Recipe updated
- 2026-09-06T06:50:26.000Z
Platforms
- linux: i386, x86_64, armv7, armv7s, arm64, mips, mips64, mipsel, mips64el, loong64, riscv64, s390x, ppc, ppc64, ppc64el, sparc64
- macosx: x86_64, arm64
- mingw: i386, x86_64, arm, arm64
- windows: x86, x64, arm, arm64, arm64ec
Options
api- OpenGL API · Type: string · Default:
debug_layer- Enable the additional GLAD debug wrappers · Type: boolean · Default: false
egl_version- EGL version · Type: string · Default: none
extensions- OpenGL extensions · Type: string · Default:
generator- Generator · Type: string · Default: c · Values: c, c-debug, d, nim, pascal, volt
gl_profile- OpenGL profile · Type: string · Values: core, compatibility
gl_version- OpenGL version · Type: string · Default: 3.3
gles1_version- GLES1 version · Type: string · Default: none
gles2_version- GLES2 version · Type: string · Default: none
glsc2_version- GLSC2 version · Type: string · Default: none
glx_version- GLX version · Type: string · Default: none
loader- Generate loader · Type: boolean · Default: true
multicontext- Enable multicontext (MX) · Type: boolean · Default: false
profile- OpenGL profile · Type: string · Default: compatibility · Values: core, compatibility
reproducible- Disable fetching the latest specification from Khronos · Type: boolean · Default: true
spec- OpenGL spec · Type: string · Default: gl
wgl_version- WGL version · Type: string · Default: none
Versions
- v0.1.34
- v0.1.36
- v2.0.8
Dependencies
No dependencies declared.
Used by (2)
Packages declaring this dependency; requirements can vary by platform and configuration.
Install with xrepo
Install the package independently of a project and inspect its available configuration.
install
xrepo install "glad 2.0.8"show info
xrepo info "glad"Link a library to your target
Declare the requirement, then attach the library to the target that uses it.
xmake.lua
add_requires("glad 2.0.8")
target("demo")
set_kind("binary")
add_files("src/*.cpp")
add_packages("glad")Open a package environment
Open a shell with the environment exported by this package. Use the executable names documented by the package.
enter shell
xrepo env -b "glad 2.0.8" shell