ajrcarey / pdfium-render

A high-level idiomatic Rust wrapper around Pdfium, the C++ PDF library used by the Google Chromium project.
https://crates.io/crates/pdfium-render
Other
364 stars 59 forks source link

Establish Rust 1.60 (or similar) as Minimum Supported Rust Version #157

Closed ajrcarey closed 2 months ago

ajrcarey commented 2 months ago

Follow-on from #137. Establish a formal MSRV for pdfium-render, aiming ideally for Rust 1.60, to be published in crate release 0.8.25.

ajrcarey commented 2 months ago

1.60 is the earliest version in which Cargo supports the dep:name style of optional dependency instantiation in crate features. If not for reliance on this in Cargo.toml, we could potentially aim for 1.59.

ajrcarey commented 2 months ago

Output from cargo-msrv states that, with current dependency tree, MSRV is 1.80. We'll need to downgrade some dependencies in order to hit 1.60.

The image crate appears particularly problematic (perhaps not surprisingly); it brings in a lot of recent dependencies which require relatively recent rust versions. Omitting the image crate feature shows MSRV 1.60 would be possible if the upper bound on the chrono dependency was changed; currently, chrono 0.4.38 requires Rust 1.61.

With image feature disabled, cargo-msrv confirms an MSRV of 1.61.

ajrcarey commented 2 months ago

Omitting image feature and limiting chrono dependency to 0.4.31 meets MSRV target of 1.60. Updated README. Included in release 0.8.25.