Feature Flags and Viewer
Added a number of feature flags for different parts of the code and dependencies, as well as the tools that go with them. Also merged in the Viewer I created a while ago in a different project, since with feature flags it now can be disabled.
Showing
... | ... | @@ -2,13 +2,48 @@ |
name = "ssif" | ||
version = "0.1.0" | ||
authors = ["Steven vanZyl <rushsteve1@rushsteve1.us>"] | ||
repository = "https://git.rushsteve1.us/rushsteve1/ssif" | ||
readme = "./README.md" | ||
license = "MIT" | ||
edition = "2018" | ||
[lib] | ||
crate-type = ["cdylib", "rlib"] | ||
autobins = false | ||
[dependencies] | ||
itertools = "0.8.0" | ||
serde = { version = "^1.0", features = ["derive"] } | ||
serde_json = "^1.0" | ||
png = "^0.15.0" | ||
\ No newline at end of file | ||
serde = { version = "^1.0", features = ["derive"], optional = true } | ||
serde_json = { version = "^1.0", optional = true } | ||
png = { version = "^0.15.0", optional = true } | ||
minifb = { version = "0.13.0", optional = true } | ||
[features] | ||
default = ["png_convert"] | ||
png_convert = ["png"] | ||
json = ["serde", "serde_json"] | ||
viewer = ["minifb"] | ||
[[bin]] | ||
name = "to_json" | ||
path = "src/bin/to_json.rs" | ||
required-features = ["json"] | ||
[[bin]] | ||
name = "from_json" | ||
path = "src/bin/from_json.rs" | ||
required-features = ["json"] | ||
[[bin]] | ||
name = "to_png" | ||
path = "src/bin/to_png.rs" | ||
required-features = ["png_convert"] | ||
[[bin]] | ||
name = "from_png" | ||
path = "src/bin/from_png.rs" | ||
required-features = ["png_convert"] | ||
[[bin]] | ||
name = "viewer" | ||
path = "src/bin/viewer.rs" | ||
required-features = ["viewer"] |
src/bin/viewer.rs
0 → 100644
Please register or sign in to comment