Makefile: specify GLSL version via command line arguments

GLSL strictly mandates the version must be the very first non-comment
statement, which results in issues when #including for templating.
This commit is contained in:
Lynne
2026-02-03 08:57:46 +01:00
parent c96b0d94eb
commit ae1a227cf6
10 changed files with 2 additions and 11 deletions

4
configure vendored
View File

@@ -7727,7 +7727,7 @@ probe_glslc(){
if test_cmd $glslc_probe -v; then
# glslang/glslangValidator
glslc=$glslc_probe
glslcflags="-V --target-env spirv1.6"
glslcflags="-V --target-env spirv1.6 --glsl-version 460"
glslc_opt_speed=""
glslc_opt_size="-Os"
glslc_opt_none="-Od"
@@ -7736,7 +7736,7 @@ probe_glslc(){
elif test_cmd $glslc_probe --version; then
# glslc
glslc=$glslc_probe
glslcflags="--target-env=vulkan1.4 --target-spv=spv1.6"
glslcflags="--target-env=vulkan1.4 --target-spv=spv1.6 -std=460"
glslc_opt_speed="-O"
glslc_opt_size="-Os"
glslc_opt_none="-O0"

View File

@@ -18,7 +18,6 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
#version 460
#pragma shader_stage(compute)
#extension GL_GOOGLE_include_directive : require

View File

@@ -18,7 +18,6 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
#version 460
#pragma shader_stage(compute)
#extension GL_GOOGLE_include_directive : require

View File

@@ -16,7 +16,6 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
#version 460
#pragma shader_stage(compute)
#extension GL_GOOGLE_include_directive : require

View File

@@ -20,7 +20,6 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
#version 460
#pragma shader_stage(compute)
#extension GL_GOOGLE_include_directive : require

View File

@@ -20,7 +20,6 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
#version 460
#pragma shader_stage(compute)
#extension GL_GOOGLE_include_directive : require

View File

@@ -16,7 +16,6 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
#version 460
#pragma shader_stage(compute)
#extension GL_GOOGLE_include_directive : require

View File

@@ -18,7 +18,6 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
#version 460
#pragma shader_stage(compute)
#extension GL_EXT_shader_image_load_formatted : require

View File

@@ -18,7 +18,6 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
#version 460
#pragma shader_stage(compute)
#extension GL_EXT_shader_image_load_formatted : require

View File

@@ -19,7 +19,6 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
#version 460
#pragma shader_stage(compute)
#extension GL_EXT_shader_image_load_formatted : require