Repository navigation
Expand file tree
/
Copy pathCargo.toml
More file actions
112 lines (100 loc) · 3.76 KB
/
Copy pathCargo.toml
File metadata and controls
112 lines (100 loc) · 3.76 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
[package]
name = "c2patool"
default-run = "c2patool"
version = "0.30.0-dev"
description = "Tool for displaying and creating C2PA manifests."
authors = [
"Gavin Peacock <gpeacock@adobe.com>",
"Maurice Fisher <mfisher@adobe.com>",
]
license = "MIT OR Apache-2.0"
documentation = "https://opensource.contentauthenticity.org/docs/c2patool"
readme = "README.md"
keywords = ["c2pa", "xmp", "metadata"]
edition = "2018"
rust-version = "1.96.0"
homepage = "https://contentauthenticity.org"
repository = "https://github.com/contentauth/c2patool"
# edition 2018 defaults to resolver "1", which unifies a dependency's
# features across ALL targets in one pass -- the target-conditional `c2pa`
# feature split below (openssl vs. rust_native_crypto, wasi vs. everything
# else) needs "2" or later to actually resolve per-target instead of
# enabling both backends at once.
resolver = "3"
[package.metadata.binstall]
bin-dir = "c2patool/{ bin }{ binary-ext }"
[package.metadata.binstall.overrides.'cfg(target_os = "macos")']
pkg-url = "{ repo }/releases/download/v{ version }/v{ version }-universal-apple-darwin.zip"
pkg-fmt = "zip"
[package.metadata.binstall.overrides.'cfg(all(target_os = "linux", target_arch = "x86_64", target_env = "gnu"))']
pkg-url = "{ repo }/releases/download/v{ version }/v{ version }-x86_64-unknown-linux-gnu.tar.gz"
pkg-fmt = "tgz"
[package.metadata.binstall.overrides.'cfg(all(target_os = "windows", target_arch = "x86_64", target_env = "msvc"))']
pkg-url = "{ repo }/releases/download/v{ version }/v{ version }-x86_64-pc-windows-msvc.zip"
pkg-fmt = "zip"
[features]
default = ["networking"]
networking = [
"c2pa/default_http"
]
[dependencies]
anyhow = "1.0"
atree = "0.5.4"
clap = { version = "4.6.1", features = ["derive", "env", "string"] }
env_logger = "0.11.10"
glob = "0.3.3"
log = "0.4"
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
toml = "1.1.2"
tempfile = "3.27"
treeline = "0.1.0"
pem = "4.0.0"
url = "2.5.8"
etcetera = "0.11.0"
# Tracks c2pa-rs's `main` branch directly (see docs/release-process.md,
# "Tracking c2pa-rs main") so integration breaks against upstream's
# in-development code surface immediately rather than only once a new
# `c2pa` version publishes. A scheduled workflow keeps Cargo.lock fresh
# against this branch. `stable` (and any `v0.*` line) uses a real crates.io
# version instead -- crates.io requires every dependency to resolve to a
# published version, so this branch is never itself published.
#
# The crypto backend feature is target-conditional, split below: `openssl`
# doesn't compile for wasm32 (c2pa-rs's own openssl dependency is itself
# gated to `not(target_arch = "wasm32")`), so the wasi target needs
# `rust_native_crypto` instead. Keep the two feature lists (everything
# except the backend name) in sync by hand.
[target.'cfg(not(target_os = "wasi"))'.dependencies]
c2pa = { git = "https://github.com/contentauth/c2pa-rs", branch = "main", features = [
"openssl",
"fetch_remote_manifests",
"file_io",
"add_thumbnails",
"pdf",
] }
reqwest = { version = "0.12.28", features = ["blocking"] }
tokio = { version = "1.52.3", features = ["rt", "rt-multi-thread"] }
[target.'cfg(windows)'.dependencies]
windows-sys = { version = "0.59", features = [
"Win32_Foundation",
"Win32_System_LibraryLoader",
] }
[target.'cfg(target_os = "wasi")'.dependencies]
c2pa = { git = "https://github.com/contentauth/c2pa-rs", branch = "main", default-features = false, features = [
"rust_native_crypto",
"fetch_remote_manifests",
"file_io",
"add_thumbnails",
"pdf",
] }
wasi = "0.14"
wstd = "0.5"
[package.metadata.cargo-udeps.ignore]
development = ["mockall"]
[dev-dependencies]
mockall = "0.15.0"
[target.'cfg(not(target_os = "wasi"))'.dev-dependencies]
assert_cmd = "2.2.2"
httpmock = "0.8.3"
predicates = "3.1"