make all the examples be their own binary crates

this achieves a few things:
- trivial way to get these shipped as the default nix package
- better dependency management
- ability to split large applications into multiple files

the README probably needs some updating.
This commit is contained in:
2022-07-06 01:30:31 -07:00
parent a61f7f4822
commit 99e7306ae9
17 changed files with 53 additions and 0 deletions

23
Cargo.lock generated
View File

@@ -165,6 +165,15 @@ dependencies = [
"serde", "serde",
] ]
[[package]]
name = "buffer_proto5"
version = "0.1.0"
dependencies = [
"coremem",
"log",
"serde",
]
[[package]] [[package]]
name = "bumpalo" name = "bumpalo"
version = "3.10.0" version = "3.10.0"
@@ -2107,6 +2116,13 @@ dependencies = [
name = "spirv_backend_runner" name = "spirv_backend_runner"
version = "0.1.0" version = "0.1.0"
[[package]]
name = "sr_latch"
version = "0.1.0"
dependencies = [
"coremem",
]
[[package]] [[package]]
name = "strsim" name = "strsim"
version = "0.8.0" version = "0.8.0"
@@ -2371,6 +2387,13 @@ version = "0.2.81"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "6a89911bd99e5f3659ec4acf9c4d93b0a90fe4a2a11f15328472058edc5261be" checksum = "6a89911bd99e5f3659ec4acf9c4d93b0a90fe4a2a11f15328472058edc5261be"
[[package]]
name = "wavefront"
version = "0.1.0"
dependencies = [
"coremem",
]
[[package]] [[package]]
name = "web-sys" name = "web-sys"
version = "0.3.57" version = "0.3.57"

View File

@@ -5,6 +5,10 @@ members = [
"crates/spirv_backend", "crates/spirv_backend",
"crates/spirv_backend_builder", "crates/spirv_backend_builder",
"crates/spirv_backend_runner", "crates/spirv_backend_runner",
"crates/applications/buffer_proto5",
"crates/applications/sr_latch",
"crates/applications/wavefront",
] ]
# [profile.release] # [profile.release]

View File

@@ -0,0 +1,10 @@
[package]
name = "buffer_proto5"
version = "0.1.0"
authors = ["Colin <colin@uninsane.org>"]
edition = "2021"
[dependencies]
coremem = { path = "../../coremem" }
log = "0.4"
serde = "1.0"

View File

@@ -0,0 +1,8 @@
[package]
name = "sr_latch"
version = "0.1.0"
authors = ["Colin <colin@uninsane.org>"]
edition = "2021"
[dependencies]
coremem = { path = "../../coremem" }

View File

@@ -0,0 +1,8 @@
[package]
name = "wavefront"
version = "0.1.0"
authors = ["Colin <colin@uninsane.org>"]
edition = "2021"
[dependencies]
coremem = { path = "../../coremem" }