[Shading]Shaderc(glslc) Building on Windows
keywords:Shaderc, glslc.exe, installation, building
Building From Source
-
Install requirements and add executable file(*.exe) in your System Environment Variables.
- Python 3
- Cmake 3.x
- Git
-
Get the sources of
shaderc
and build in cmake.git clone https://github.com/google/shaderc $SOURCE_DIR cd $SOURCE_DIR py ./utils/git-sync-deps cd $SOURCE_DIR/ mkdir $BUILD_DIR && cd $BUILD_DIR cmake $SOURCE_DIR cmake --build . --config {Release|Debug|MinSizeRel|RelWithDebInfo} ctest -C {Release|Debug|MinSizeRel|RelWithDebInfo}
Only one $(Configuration)
can be setup upon executing cmake --build
, e.g. Release
:
cmake --build . --config Release
Otherwise you would get an error:
'Debug' is not recognized as an internal or external command,
glslc.exe would be generated in following directory at the end of building.
$BUILD_DIR\glslc\Release\glslc.exe
Download Binaries Directly
https://github.com/google/shaderc#downloads
or:
https://www.lunarg.com/vulkan-sdk/
directory:
%VULKAN_SDK%/Bin/glslc.exe
Reference
A collection of tools, libraries, and tests for Vulkan shader compilation.
https://github.com/google/shaderc
nothing in this world was more difficult than love. ― Gabriel García Márquez