summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Samuelsson <msamuelsson@storvix.eu>2023-05-27 13:14:25 +0200
committerMartin Samuelsson <msamuelsson@storvix.eu>2023-05-28 23:12:12 +0200
commit421aedc55865ed9075f4e2df1dfbb71e7987424a (patch)
tree5c7aa8b7d822077cd978a48df5f5506732f960ef
parent686214f80c5eab30e67e34890c332e0232ca5afa (diff)
downloadlibsyslog-rs-421aedc55865ed9075f4e2df1dfbb71e7987424a.zip
Make bitflags a default feature
This change is due to bitflags version 2.0 having been released. Unlike what was mentioned in the source code comment, removed by this commit, the feature is not getting deprecated. It makes some sense to keep the feature around for those who do not need it. Every dependency reduced is a win.
-rw-r--r--libsyslog/CHANGELOG.md5
-rw-r--r--libsyslog/Cargo.toml3
-rw-r--r--libsyslog/src/lib.rs1
3 files changed, 7 insertions, 2 deletions
diff --git a/libsyslog/CHANGELOG.md b/libsyslog/CHANGELOG.md
index 0a0e2e7..e5525b8 100644
--- a/libsyslog/CHANGELOG.md
+++ b/libsyslog/CHANGELOG.md
@@ -12,6 +12,11 @@ adheres to [Semantic Versioning][semver].
- Stop insecurely passing untrusted data syslog().
+### Changed
+
+ - Switch bitflags to being a default feature, thus exposing the Logopt struct
+ SyslogBuilder::logopt() method by default.
+
## 0.1.0 - 2023-02-24
Initial release.
diff --git a/libsyslog/Cargo.toml b/libsyslog/Cargo.toml
index 5d6e904..7128827 100644
--- a/libsyslog/Cargo.toml
+++ b/libsyslog/Cargo.toml
@@ -8,9 +8,10 @@ repository = "https://git.netizen.se/libsyslog-rs/"
keywords = [ "logging", "syslog" ]
[dependencies]
-bitflags = { version = "2.0.0-rc.3", optional = true }
+bitflags = { version = "2.0.2", optional = true }
libsyslog-sys = { version = "0.1.0", path = "../libsyslog-sys" }
log = { version = "0.4.17", features = [ "std" ] }
[features]
+default = ["bitflags"]
bitflags = [ "dep:bitflags" ]
diff --git a/libsyslog/src/lib.rs b/libsyslog/src/lib.rs
index 7c253ae..904f3ea 100644
--- a/libsyslog/src/lib.rs
+++ b/libsyslog/src/lib.rs
@@ -52,7 +52,6 @@ compile_error!("AIX user, please help with the code comment above this error.");
mod builder;
mod facility;
-// TODO Deprecate feature once the bitflags crate reaches 2.0.0.
#[cfg(feature = "bitflags")]
mod logopt;
mod syslog;