rust-pcap / pcap

Rust language pcap library
Apache License 2.0
617 stars 142 forks source link

Update libloading from 0.6 to 0.8 #346

Closed musicinmybrain closed 5 months ago

musicinmybrain commented 5 months ago

Deal with the fact that libloading::Library::new was declared unsafe in libloading 0.7; see https://github.com/nagisa/rust_libloading/issues/86 and https://github.com/nagisa/rust_libloading/blob/0.8.3/src/changelog.rs#L96-L151 for details.

Fixes #345.

Wojtek242 commented 5 months ago

Whilst I don't expect all CI jobs to pass at the moment, the Windows MSRV should pass, but it does not here: https://github.com/rust-pcap/pcap/actions/runs/8724374552/job/23943643474?pr=346. It appears that libloading introduced a dependency that requires a newer rust compiler.

Here's what you can do:

  1. See if it will work with MSRV 1.63 which is Debian's rustc version. You can grep for msrv to see where you can change the CI to this version. You can also test older rust versions locally with rustup.
  2. If the above doesn't work, perhaps a version of libloading newer than 0.6, but older than the latest one will work.
musicinmybrain commented 5 months ago

Thanks. I will investigate.

musicinmybrain commented 5 months ago

Since libloading cites an MSRV of 1.56 as of 0.8.2, I’m trying that first. Hopefully I’ve tweaked everything correctly.

musicinmybrain commented 5 months ago

It looks like this now has no more CI failures than https://github.com/rust-pcap/pcap/pull/348 does.

Wojtek242 commented 5 months ago

It looks like this now has no more CI failures than #348 does.

Yes, the CI currently fails in the same places as main. I will merge and publish soon. Thanks for the PR!

musicinmybrain commented 5 months ago

You’re welcome! Glad it is useful.