mirror of
https://github.com/gfx-rs/wgpu.git
synced 2026-04-22 03:02:01 -04:00
Ues updated paths in Makefile
This commit is contained in:
committed by
Dzmitry Malyshau
parent
31be7099f2
commit
832e259a03
27
Makefile
27
Makefile
@@ -1,13 +1,14 @@
|
||||
.PHONY: all clean validate-spv validate-msl
|
||||
.SECONDARY: boids.metal quad.metal
|
||||
SNAPSHOTS=tests/snapshots
|
||||
SNAPSHOTS_IN=tests/in
|
||||
SNAPSHOTS_OUT=tests/out
|
||||
|
||||
all:
|
||||
|
||||
clean:
|
||||
rm *.metal *.air *.metallib *.vert *.frag *.comp *.spv
|
||||
|
||||
%.metal: $(SNAPSHOTS)/in/%.wgsl $(wildcard src/*.rs src/**/*.rs examples/*.rs)
|
||||
%.metal: $(SNAPSHOTS_IN)/%.wgsl $(wildcard src/*.rs src/**/*.rs examples/*.rs)
|
||||
cargo run --example convert --features wgsl-in,msl-out -- $< $@
|
||||
|
||||
%.air: %.metal
|
||||
@@ -24,28 +25,28 @@ clean:
|
||||
cargo run --example convert --features wgsl-in,glsl-out -- $< $@
|
||||
glslangValidator $@
|
||||
|
||||
validate-spv: $(SNAPSHOTS)/*.spvasm.snap
|
||||
validate-spv: $(SNAPSHOTS_OUT)/*.spvasm.snap
|
||||
@for file in $^ ; do \
|
||||
echo "Validating" $${file#"$(SNAPSHOTS)/snapshots__"}; \
|
||||
echo "Validating" $${file#"$(SNAPSHOTS_OUT)/snapshots__"}; \
|
||||
tail -n +5 $${file} | spirv-as --target-env vulkan1.0 -o - | spirv-val; \
|
||||
done
|
||||
|
||||
validate-msl: $(SNAPSHOTS)/*.msl.snap
|
||||
validate-msl: $(SNAPSHOTS_OUT)/*.msl.snap
|
||||
@for file in $^ ; do \
|
||||
echo "Validating" $${file#"$(SNAPSHOTS)/snapshots__"}; \
|
||||
echo "Validating" $${file#"$(SNAPSHOTS_OUT)/snapshots__"}; \
|
||||
tail -n +5 $${file} | xcrun -sdk macosx metal -mmacosx-version-min=10.11 -x metal - -o /dev/null; \
|
||||
done
|
||||
|
||||
validate-glsl: $(SNAPSHOTS)/*.glsl.snap
|
||||
@for file in $(SNAPSHOTS)/*-Vertex.glsl.snap ; do \
|
||||
echo "Validating" $${file#"$(SNAPSHOTS)/snapshots__"};\
|
||||
validate-glsl: $(SNAPSHOTS_OUT)/*.glsl.snap
|
||||
@for file in $(SNAPSHOTS_OUT)/*-Vertex.glsl.snap ; do \
|
||||
echo "Validating" $${file#"$(SNAPSHOTS_OUT)/snapshots__"};\
|
||||
tail -n +5 $${file} | glslangValidator --stdin -S vert; \
|
||||
done
|
||||
@for file in $(SNAPSHOTS)/*-Fragment.glsl.snap ; do \
|
||||
echo "Validating" $${file#"$(SNAPSHOTS)/snapshots__"};\
|
||||
@for file in $(SNAPSHOTS_OUT)/*-Fragment.glsl.snap ; do \
|
||||
echo "Validating" $${file#"$(SNAPSHOTS_OUT)/snapshots__"};\
|
||||
tail -n +5 $${file} | glslangValidator --stdin -S frag; \
|
||||
done
|
||||
@for file in $(SNAPSHOTS)/*-Compute.glsl.snap ; do \
|
||||
echo "Validating" $${file#"$(SNAPSHOTS)/snapshots__"};\
|
||||
@for file in $(SNAPSHOTS_OUT)/*-Compute.glsl.snap ; do \
|
||||
echo "Validating" $${file#"$(SNAPSHOTS_OUT)/snapshots__"};\
|
||||
tail -n +5 $${file} | glslangValidator --stdin -S comp; \
|
||||
done
|
||||
|
||||
Reference in New Issue
Block a user