[package]
name = "rpfm_lib"
description = "This crate contains the basic functionality for interacting with Total War files."
license = "MIT"
repository = "https://github.com/Frodo45127/rpfm"
categories = ["games"]
keywords = ["totalwar", "modding"]
readme = "README.md"

version.workspace = true
authors.workspace = true
edition.workspace = true
rust-version.workspace = true

[features]
default = ["integration_sqlite", "integration_assembly_kit"]

support_error_bincode = ["dep:bincode"]
enable_content_inspector = []

integration_assembly_kit = ["dep:serde-xml-rs"]
integration_git = ["dep:git2"]
integration_log = ["dep:backtrace", "dep:log", "dep:os_info", "dep:sentry", "dep:simplelog"]
integration_sqlite = ["dep:rusqlite", "dep:r2d2_sqlite", "dep:r2d2"]

support_rigidmodel = []
support_uic = []
support_soundbank = []

[dependencies]

# Basic get/set support.
getset = "^0.1"

# Serialization support.
serde = "^1.0"
serde_derive = "^1.0"
serde_json = "^1.0"
serde-xml-rs = { version = "^0.6", optional = true }
csv = "^1.1"
ron = "^0.8"
toml = "^0.7"
bincode = { version = "^1.3", optional = true }

# Error handling.
thiserror = "1.0"

# Decoding/Encoding support.
itertools = "^0.10"
byteorder = "^1.3"
encoding_rs = "^0.8"
bitflags = "^1.0"

# Regex support.
regex = "^1"

# RNG support.
rand = "^0.8"

# Git support.
git2 = { version = "^0.16", optional = true }

# Pelite, because we need it to get the current version of a game's exe, and I have not a fucking clue how to pass a path to WinApi.
pelite = "^0.10"

# Multithread iterator support.
rayon = "^1.3"

# SQLite support
rusqlite = { version = "^0.28", optional = true, features = ["blob", "bundled"] }
r2d2_sqlite = { version = "^0.21", optional = true }
r2d2 = { version = "^0.8", optional = true }

# Compression support.
xz2 = "^0.1"

# Fractions support
fraction = "^0.13"

# Case-insensitive checks.
caseless = "^0.2"

# UUID Generation support.
uuid = { version = "^1.1", features = ["v4"] }

# Quick char search support.
memchr = "^2.5"

# Float equality support.
float_eq = "^1"

# Regex globals support.
lazy_static = "^1.2"

# Logging support.
backtrace = { version = "^0.3", optional = true }
log = { version = "^0.4", optional = true, features = ["std"] }
os_info = { version = "^3.0", optional = true }
sentry = { version = "^0", optional = true, features = ["log"] }
simplelog = { version = "^0.12", optional = true }

# Support for finding unsupported text files.
content_inspector = { version = "^0.2" }

# Steam Location support.
steamlocate = "2.0.0-alpha.0"
