mirror of
https://github.com/Rust-GPU/rust-gpu.git
synced 2026-06-08 10:39:50 +09:00
123 lines
4.5 KiB
TOML
123 lines
4.5 KiB
TOML
# HACK(eddyb) meant for `[profile.dev]` `rustflags` overrides below, but sadly
|
|
# not configurable w/o breaking `Cargo.toml` parsing from non-nightly Cargo.
|
|
#
|
|
# cargo-features = ["profile-rustflags"]
|
|
|
|
[workspace]
|
|
resolver = "2"
|
|
members = [
|
|
"examples/runners/cpu",
|
|
"examples/runners/ash",
|
|
"examples/runners/wgpu",
|
|
"examples/runners/wgpu/builder",
|
|
"examples/shaders/reduce",
|
|
"examples/shaders/sky-shader",
|
|
"examples/shaders/simplest-shader",
|
|
"examples/shaders/compute-shader",
|
|
"examples/shaders/mouse-shader",
|
|
"examples/multibuilder",
|
|
"examples/run-wasm",
|
|
|
|
"crates/rustc_codegen_spirv",
|
|
"crates/rustc_codegen_spirv-types",
|
|
"crates/spirv-builder",
|
|
"crates/spirv-std",
|
|
"crates/spirv-std/shared",
|
|
"crates/spirv-std/macros",
|
|
"crates/cargo-gpu",
|
|
"crates/cargo-gpu-install",
|
|
"crates/xtask",
|
|
|
|
"tests/compiletests",
|
|
"tests/compiletests/deps-helper",
|
|
"tests/difftests/bin",
|
|
"tests/difftests/lib",
|
|
]
|
|
|
|
exclude = [
|
|
# This currently needs to be excluded because it depends on a version of `rust-gpu` that
|
|
# uses a toolchain whose Cargo version doesn't recognise version 4 of `Cargo.lock`.
|
|
"crates/shader-crate-template",
|
|
# Testing infra may copy the `shader-crate-template` into subdirs of target
|
|
"target",
|
|
]
|
|
|
|
[workspace.package]
|
|
version = "0.9.0"
|
|
authors = ["rust-gpu developers", "Embark <opensource@embark-studios.com>"]
|
|
edition = "2024"
|
|
license = "MIT OR Apache-2.0"
|
|
repository = "https://github.com/rust-gpu/rust-gpu"
|
|
keywords = ["gpu", "compiler", "rust-gpu"]
|
|
|
|
[workspace.lints.rust]
|
|
unexpected_cfgs = { level = "allow", check-cfg = ['cfg(target_arch, values("spirv"))'] }
|
|
|
|
[workspace.dependencies]
|
|
spirv-builder = { path = "./crates/spirv-builder", version = "=0.9.0", default-features = false }
|
|
spirv-std = { path = "./crates/spirv-std", version = "=0.9.0" }
|
|
spirv-std-types = { path = "./crates/spirv-std/shared", version = "=0.9.0" }
|
|
spirv-std-macros = { path = "./crates/spirv-std/macros", version = "=0.9.0" }
|
|
spirv-tools = { version = "0.13.0", default-features = false }
|
|
rustc_codegen_spirv = { path = "./crates/rustc_codegen_spirv", version = "=0.9.0", default-features = false }
|
|
rustc_codegen_spirv-types = { path = "./crates/rustc_codegen_spirv-types", version = "=0.9.0" }
|
|
cargo-gpu-install = { path = "./crates/cargo-gpu-install" }
|
|
|
|
# normal dependencies
|
|
anyhow = "1.0.98"
|
|
clap = { version = "4.5.41", features = ["derive"] }
|
|
crossterm = { version = "0.29.0", default-features = false, features = ["events", "windows"] }
|
|
directories = "6.0.0"
|
|
env_logger = "0.11.8"
|
|
log = "0.4"
|
|
relative-path = "2.0.1"
|
|
serde = { version = "1.0.219", features = ["derive"] }
|
|
serde_json = "1.0.141"
|
|
toml = "0.9.2"
|
|
tempfile = "3.22"
|
|
test-log = "0.2.18"
|
|
cargo_metadata = "0.21.0"
|
|
cargo-util-schemas = "0.8.2"
|
|
semver = "1.0.26"
|
|
dunce = "1.0.5"
|
|
expect-test = "1.5.1"
|
|
regex-lite = "0.1.9"
|
|
|
|
# difftest libraries mirrored from difftest workspace
|
|
difftest = { path = "tests/difftests/lib" }
|
|
|
|
# External dependencies that need to be mentioned more than once.
|
|
tracing = "0.1"
|
|
tracing-subscriber = { version = "0.3.20", features = ["env-filter", "json"] }
|
|
num-traits = { version = "0.2.15", default-features = false }
|
|
glam = { version = ">=0.30.8", default-features = false }
|
|
libm = { version = "0.2.5", default-features = false }
|
|
bytemuck = { version = "1.23", features = ["derive"] }
|
|
|
|
# Enable incremental by default in release mode.
|
|
[profile.release]
|
|
incremental = true
|
|
# HACK(eddyb) this is the default but without explicitly specifying it, Cargo
|
|
# will treat the identical settings in `[profile.release.build-override]` below
|
|
# as different sets of `rustc` flags and will not reuse artifacts between them.
|
|
codegen-units = 256
|
|
|
|
# Compile build-dependencies in release mode with the same settings
|
|
# as regular dependencies (including the incremental enabled above).
|
|
[profile.release.build-override]
|
|
opt-level = 3
|
|
incremental = true
|
|
codegen-units = 256
|
|
|
|
# HACK(eddyb) reduce the number of linker exports and/or imports, by avoiding
|
|
# inter-CGU linkage, to stay under the 64Ki MSVC limit for `rustc_codegen_spirv`
|
|
# when building it in "debug mode" (only relevant to CI for now, realistically),
|
|
# i.e. working around this issue: https://github.com/rust-lang/rust/issues/53014.
|
|
[profile.dev]
|
|
# HACK(eddyb) fewer inter-crate exports/imports (not just inter-CGU), but sadly
|
|
# not configurable w/o breaking `Cargo.toml` parsing from non-nightly Cargo
|
|
# (moved to `.github/workflows/ci.yaml` as `RUSTFLAGS: -Zshare-generics=off`).
|
|
#
|
|
# rustflags = ["-Zshare-generics=off"]
|
|
codegen-units = 1
|