Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

vulkan feature exclude macOS and iOS by default #3292

Merged
merged 2 commits into from
Jan 4, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 13 additions & 1 deletion player/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ publish = false

[features]
angle = ["wgc/angle"]
vulkan-portability = ["wgc/vulkan-portability"]
vulkan-portability = ["wgc/vulkan"]

[dependencies]
env_logger.workspace = true
Expand All @@ -29,5 +29,17 @@ features = ["replay"]
workspace = true
features = ["replay", "raw-window-handle", "strict_asserts", "wgsl"]

[target.'cfg(any(target_os = "macos", target_os = "ios"))'.dependencies.wgc]
workspace = true
features = ["metal"]

[target.'cfg(windows)'.dependencies.wgc]
workspace = true
features = ["dx11", "dx12"]

[target.'cfg(any(windows, all(unix, not(target_arch = "emscripten"), not(target_os = "ios"), not(target_os = "macos"))))'.dependencies.wgc]
workspace = true
features = ["vulkan"]

[dev-dependencies]
serde.workspace = true
1 change: 0 additions & 1 deletion wgpu-core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ serial-pass = ["serde", "wgt/serde", "arrayvec/serde"]
id32 = []
# Enable `ShaderModuleSource::Wgsl`
wgsl = ["naga/wgsl-in"]
vulkan-portability = ["hal/vulkan"]

# Features that are intended to work on all platforms.
portable_features = ["gles", "strict_asserts", "trace", "replay", "serial-pass", "id32", "wgsl"]
Expand Down
4 changes: 2 additions & 2 deletions wgpu/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ replay = ["serde", "wgc/replay"]
angle = ["wgc/angle"]
webgl = ["hal", "wgc"]
emscripten = ["webgl"]
vulkan-portability = ["wgc/vulkan-portability"]
vulkan-portability = ["wgc/vulkan"]
expose-ids = []

# wgpu-core is always available as an optional dependency, "wgc".
Expand Down Expand Up @@ -115,7 +115,7 @@ workspace = true
features = ["dx11", "dx12"]

# We want the wgpu-core Vulkan backend on Unix (but not Emscripten) and Windows.
[target.'cfg(any(windows, all(unix, not(target_arch = "emscripten"))))'.dependencies.wgc]
[target.'cfg(any(windows, all(unix, not(target_arch = "emscripten"), not(target_os = "ios"), not(target_os = "macos"))))'.dependencies.wgc]
workspace = true
features = ["vulkan"]

Expand Down