The glslc program is Google's command line compiler for OpenGL Shading Language/High Level Shading Language (GLSL/HLSL) to Standard Portable Intermediate Representation (SPIR-V).
This package is known to build and work properly using an LFS 12.4 platform.
Download (HTTP): https://github.com/google/shaderc/archive/v2025.4/shaderc-2025.4.tar.gz
Download SHA256 Sum: 8a89fb6612ace8954470aae004623374a8fc8b7a34a4277bee5527173b064faf
Download MD5 sum: 02208e374e610808c4ca3b1e7627b82d
Download size: 1,181.4 KB
Estimated disk space required: 3,161.3 KB
Estimated build time: less than 0.5 SBU
First, allow building with system Glslang-16.0.0 and SPIRV-Tools-1.4.328.1:
sed '/build-version/d' -i glslc/CMakeLists.txt sed '/third_party/d' -i CMakeLists.txt sed 's|SPIRV|glslang/&|' -i libshaderc_util/src/compiler.cc echo '"2025.4"' > glslc/src/build-version.inc
Now Prepare glslc by running the following commands:
cmake -B build -G Ninja \
-D CMAKE_INSTALL_PREFIX=/usr \
-D CMAKE_BUILD_TYPE=Release \
-D SHADERC_SKIP_TESTS=ONninja -C build
Now Install the package, as the root user:
install -vm755 glslc/glslc /usr/bin