1[package]
2authors = [
3 "Jyun-Yan You <jyyou.tw@gmail.com>",
4 "Emilio Cobos Álvarez <emilio@crisal.io>",
5 "Nick Fitzgerald <fitzgen@gmail.com>",
6 "The Servo project developers",
7]
8description = "Automatically generates Rust FFI bindings to C and C++ libraries."
9keywords = ["bindings", "ffi", "code-generation"]
10categories = ["external-ffi-bindings", "development-tools::ffi"]
11license = "BSD-3-Clause"
12name = "bindgen"
13readme = "../README.md"
14repository = "https://github.com/rust-lang/rust-bindgen"
15documentation = "https://docs.rs/bindgen"
16homepage = "https://rust-lang.github.io/rust-bindgen/"
17version = "0.70.1"
18edition = "2018"
19build = "build.rs"
20# If you change this, also update README.md and msrv in .github/workflows/bindgen.yml
21rust-version = "1.70.0"
22
23[lib]
24name = "bindgen"
25path = "lib.rs"
26
27[dependencies]
28annotate-snippets = { version = "0.9.1", features = ["color"], optional = true }
29bitflags = "2.2.1"
30cexpr = "0.6"
31clang-sys = { version = "1", features = ["clang_6_0"] }
32itertools = { version = ">=0.10,<0.14", default-features = false }
33log = { version = "0.4", optional = true }
34prettyplease = { version = "0.2.7", optional = true, features = ["verbatim"] }
35proc-macro2 = { version = "1", default-features = false }
36quote = { version = "1", default-features = false }
37regex = { version = "1.5.3", default-features = false, features = ["std", "unicode-perl"] }
38rustc-hash = "1.0.1"
39shlex = "1"
40syn = { version = "2.0", features = ["full", "extra-traits", "visit-mut"] }
41
42[features]
43default = ["logging", "prettyplease", "runtime"]
44logging = ["dep:log"]
45static = ["clang-sys/static"]
46runtime = ["clang-sys/runtime"]
47# This feature is no longer used for anything and should be removed in bindgen 0.70
48which-rustfmt = []
49experimental = ["dep:annotate-snippets"]
50
51## The following features are for internal use and they shouldn't be used if
52## you're not hacking on bindgen
53# Features used by `bindgen-cli`
54__cli = []
55# Features used for CI testing
56__testing_only_extra_assertions = []
57__testing_only_libclang_9 = []
58__testing_only_libclang_16 = []
59
60[package.metadata.docs.rs]
61features = ["experimental"]
62
63[package.metadata.release]
64release = true
65pre-release-hook = ["../node_modules/doctoc/doctoc.js", "../CHANGELOG.md"]
66
67# Add version and date to changelog file
68[[package.metadata.release.pre-release-replacements]]
69file = "../CHANGELOG.md"
70search = "# Unreleased"
71replace = "# Unreleased\n## Added\n## Changed\n## Removed\n## Fixed\n## Security\n\n# {{version}} ({{date}})"
72