sqlx/sqlx-macros-core/Cargo.toml
依云 5b8bb3b28b
Add a "sqlite-unbundled" feature that dynamically links to system libsqlite3.so library (#3507)
* Add a "sqlite-unbundled" feature that dynamically links to system libsqlite3.so library

* update README abouot the newly-added `sqlite-unbundled` feature

* Update README.md to make it clear with bulleted list

Co-authored-by: Austin Bonander <austin.bonander@gmail.com>

* more cfg feature updates

Co-authored-by: Austin Bonander <austin.bonander@gmail.com>

* update documentation in sqlx-sqlx/src/lib.rs too

and also mention possible build time increasement.

* cargo fmt

* Add "sqlite-unbundled" feature to sqlx-cli

* Add sqlite-unbundled to gituhb actions tests

* cfg(feature = "sqlite") => cfg(any(feature = "sqlite", feature = "sqlite-unbundled"))

* fix

* CI: make sqlite-unbundled tests workaround required-features

by duplicating the relevant test section

* use an internal "_sqlite" feature to do the conditional compilation

---------

Co-authored-by: Austin Bonander <austin.bonander@gmail.com>
2024-10-02 11:55:21 -07:00

73 lines
2.7 KiB
TOML

[package]
name = "sqlx-macros-core"
description = "Macro support core for SQLx, the Rust SQL toolkit. Not intended to be used directly."
version.workspace = true
license.workspace = true
edition.workspace = true
authors.workspace = true
repository.workspace = true
[features]
default = []
# for conditional compilation
_rt-async-std = ["async-std", "sqlx-core/_rt-async-std"]
_rt-tokio = ["tokio", "sqlx-core/_rt-tokio"]
_tls-native-tls = ["sqlx-core/_tls-native-tls"]
_tls-rustls-aws-lc-rs = ["sqlx-core/_tls-rustls-aws-lc-rs"]
_tls-rustls-ring = ["sqlx-core/_tls-rustls-ring"]
_sqlite = []
# SQLx features
derive = []
macros = []
migrate = ["sqlx-core/migrate"]
# database
mysql = ["sqlx-mysql"]
postgres = ["sqlx-postgres"]
sqlite = ["_sqlite", "sqlx-sqlite/bundled"]
sqlite-unbundled = ["_sqlite", "sqlx-sqlite/unbundled"]
# type integrations
json = ["sqlx-core/json", "sqlx-mysql?/json", "sqlx-postgres?/json", "sqlx-sqlite?/json"]
bigdecimal = ["sqlx-core/bigdecimal", "sqlx-mysql?/bigdecimal", "sqlx-postgres?/bigdecimal"]
bit-vec = ["sqlx-core/bit-vec", "sqlx-postgres?/bit-vec"]
chrono = ["sqlx-core/chrono", "sqlx-mysql?/chrono", "sqlx-postgres?/chrono", "sqlx-sqlite?/chrono"]
ipnetwork = ["sqlx-core/ipnetwork", "sqlx-postgres?/ipnetwork"]
mac_address = ["sqlx-core/mac_address", "sqlx-postgres?/mac_address"]
rust_decimal = ["sqlx-core/rust_decimal", "sqlx-mysql?/rust_decimal", "sqlx-postgres?/rust_decimal"]
time = ["sqlx-core/time", "sqlx-mysql?/time", "sqlx-postgres?/time", "sqlx-sqlite?/time"]
uuid = ["sqlx-core/uuid", "sqlx-mysql?/uuid", "sqlx-postgres?/uuid", "sqlx-sqlite?/uuid"]
[dependencies]
sqlx-core = { workspace = true, features = ["offline"] }
sqlx-mysql = { workspace = true, features = ["offline", "migrate"], optional = true }
sqlx-postgres = { workspace = true, features = ["offline", "migrate"], optional = true }
sqlx-sqlite = { workspace = true, features = ["offline", "migrate"], optional = true }
async-std = { workspace = true, optional = true }
tokio = { workspace = true, optional = true }
dotenvy = { workspace = true }
hex = { version = "0.4.3" }
heck = { version = "0.5" }
either = "1.6.1"
once_cell = "1.9.0"
proc-macro2 = { version = "1.0.79", default-features = false }
serde = { version = "1.0.132", features = ["derive"] }
serde_json = { version = "1.0.73" }
sha2 = { version = "0.10.0" }
syn = { version = "2.0.52", default-features = false, features = ["full", "derive", "parsing", "printing", "clone-impls"] }
tempfile = { version = "3.10.1" }
quote = { version = "1.0.26", default-features = false }
url = { version = "2.2.2", default-features = false }
[lints.rust.unexpected_cfgs]
level = "warn"
# 1.80 will warn without this
check-cfg = ['cfg(sqlx_macros_unstable)', 'cfg(procmacro2_semver_exempt)']