Skip to content

Commit 6716149

Browse files
committed
working static build
1 parent 99d216b commit 6716149

File tree

4 files changed

+8
-49
lines changed

4 files changed

+8
-49
lines changed

Cargo.toml

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
11
[workspace]
2-
members = [
3-
"crates/minislang",
4-
"crates/slang-hal",
5-
"crates/slang-hal-derive",
6-
]
2+
members = ["crates/minislang", "crates/slang-hal", "crates/slang-hal-derive"]
73
resolver = "2"
84

95
[workspace.dependencies]
@@ -24,12 +20,15 @@ encase = "0.12"
2420

2521
[workspace.lints]
2622
rust.unexpected_cfgs = { level = "warn", check-cfg = [
27-
'cfg(feature, values("dim2", "dim3"))'
23+
'cfg(feature, values("dim2", "dim3"))',
2824
] }
2925

3026
[profile.release]
3127
opt-level = 'z'
3228

3329
[patch.crates-io]
3430
#encase = { path = "../encase" }
35-
#shader-slang = { path = "../slang-rs" }
31+
#shader-slang = { path = "../slang-rs" }
32+
shader-slang = { git = "https://github.com/Vrixyz/slang-rs.git", branch = "static-build", default-features = false, features = [
33+
"static",
34+
] }

crates/minislang/src/lib.rs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -97,9 +97,7 @@ impl SlangCompiler {
9797

9898
let entry_points: Vec<_> = module
9999
.entry_points()
100-
.filter(|e| {
101-
entry_point.is_none() || Some(e.function_reflection().name()) == entry_point
102-
})
100+
.filter(|e| entry_point.is_none() || e.function_reflection().name() == entry_point)
103101
.map(|e| e.downcast().clone())
104102
.collect();
105103
let program = session

crates/slang-hal/build.rs

Lines changed: 0 additions & 38 deletions
This file was deleted.

crates/slang-hal/src/function.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ impl<B: Backend> GpuFunction<B> {
5353
buffers.push((
5454
param_var
5555
.name()
56-
// .expect("unnamed parameters not supported yet")
56+
.expect("unnamed parameters not supported yet")
5757
.to_string(),
5858
binding,
5959
));

0 commit comments

Comments
 (0)