oxipng/Cargo.toml
andrews05 f4e631bce7
Feature/manpage (#596)
This PR adds a build script to generate a man page using clap_mangen, as
per this example:
https://github.com/sondr3/clap-man-example/blob/main/build.rs

I'm not sure what to actually do with the man file from here, I guess
it's up to the packaging process to do something with it?
See
https://github.com/shssoichiro/oxipng/issues/69#issuecomment-1963352536

Note I couldn't see a way to include the `DISPLAY` chunk names from the
constant as we did before. They're now just hardcoded into the help and
will require manually updating if the list changes.

Closes #526

---------

Co-authored-by: Alejandro González <me@alegon.dev>
2024-03-18 12:28:52 +01:00

110 lines
2.3 KiB
TOML

[package]
authors = ["Joshua Holmer <jholmer.in@gmail.com>"]
categories = ["command-line-utilities", "compression"]
description = "A lossless PNG compression optimizer"
documentation = "https://docs.rs/oxipng"
edition = "2021"
exclude = [
".editorconfig",
".gitattributes",
".github/*",
".gitignore",
".pre-commit-hooks.yaml",
"Dockerfile",
"scripts/*",
"tests/*",
]
homepage = "https://github.com/shssoichiro/oxipng"
license = "MIT"
name = "oxipng"
repository = "https://github.com/shssoichiro/oxipng"
version = "9.0.0"
rust-version = "1.66.0"
[badges]
travis-ci = { repository = "shssoichiro/oxipng", branch = "master" }
maintenance = { status = "actively-developed" }
[[bin]]
doc = false
name = "oxipng"
path = "src/main.rs"
required-features = ["binary"]
[[bench]]
name = "zopfli"
required-features = ["zopfli"]
[dependencies]
zopfli = { version = "0.8.0", optional = true, default-features = false, features = ["std", "zlib"] }
rgb = "0.8.36"
indexmap = "2.0.0"
libdeflater = "1.19.0"
log = "0.4.19"
bitvec = "1.0.1"
rustc-hash = "1.1.0"
[dependencies.env_logger]
optional = true
default-features = false
features = ["auto-color"]
version = "0.10.0"
[dependencies.crossbeam-channel]
optional = true
version = "0.5.8"
[dependencies.filetime]
optional = true
version = "0.2.21"
[dependencies.rayon]
optional = true
version = "1.7.0"
[dependencies.clap]
optional = true
version = "4.3.8"
features = ["wrap_help"]
[target.'cfg(windows)'.dependencies.glob]
optional = true
version = "0.3.1"
[dependencies.image]
optional = true
default-features = false
features = ["png"]
version = "0.24.6"
[build-dependencies]
clap = "4.3.8"
clap_mangen = "0.2.12"
rustc_version = "0.4.0"
[features]
binary = ["clap", "glob", "env_logger"]
default = ["binary", "filetime", "parallel", "zopfli"]
parallel = ["rayon", "indexmap/rayon", "crossbeam-channel"]
freestanding = ["libdeflater/freestanding"]
sanity-checks = ["image"]
[lib]
name = "oxipng"
path = "src/lib.rs"
[profile.dev]
opt-level = 2
[profile.release]
lto = "fat"
strip = "symbols"
panic = "abort"
[package.metadata.deb]
assets = [
["target/release/oxipng", "usr/bin/", "755"],
["generated/assets/oxipng.1", "usr/share/man/man1/", "644"],
["README.md", "usr/share/doc/oxipng/", "644"],
["CHANGELOG.md", "usr/share/doc/oxipng/", "644"],
]