Conversation
f4f77a8 to
e6ca8c5
Compare
LegNeato
left a comment
There was a problem hiding this comment.
Wait, we have cargo-gpu, spirvbuilder, and cargo-gpu-install?!?! That seems really bad and confusing.
Can't we just put this behind an off-by-default flag (looks like it is on?) that is turned on for the binary? That way people using cargo-gpu in teh build script don't get changes in behavior and we still get this feature.
So I guess I don't see why cargo-gpu-install even exists?
No we can't, cause if you So our only option was to split the crate in two, a library crate for build scripts ( For additional background:
|
|
Ahhh, I see. Thanks for explaining. |
| use clap::Args; | ||
| use std::path::PathBuf; | ||
|
|
||
| const TEMPLATE_REPO: &str = "https://github.com/Rust-GPU/rust-gpu-template.git"; |
There was a problem hiding this comment.
Make this configurable with this as the default so you can point at branches or whatever to test?
| /// at least one parameter and instead prints help. | ||
| #[derive(Default, Debug, Clone, Args)] | ||
| #[command(arg_required_else_help(false))] | ||
| pub struct Generate { |
There was a problem hiding this comment.
We should support --lib and --bin like cargo, right now it assumes a certain opinionated shape. How do we specify shader types to include or not include? I glanced over the template and it seems to assume graphics. Should we default to compute (less boilerplate / host code needed) and be able to specify which shader stages to generate? Should we even have a default?
cargo-gpu neweffectively aliasescargo generatewith the rust-gpu-template repocargo-gpudepend oncargo-generate, which significantly increases the amount of dependenciescargo-gpuhas. I expect most users to migrate tocargo-gpu-installfor their build script needs.cargo-gpuas a dep, I've madecargo-generatea default feature you can disablecargo generatealso depends on quite a few outdated packages, including vulnerabilities, making ourcargo denycomplain. I've made it pass by ignoring them all, as I don't think there's a huge concern for a dev cmdline tool.close #576