Project

General

Profile

Feature #2629

Rust2018 Tracking

Added by Danny Browning 10 months ago. Updated 9 days ago.

Status:
New
Priority:
Normal
Assignee:
Target version:
Effort:
Difficulty:
Label:

Description

Rust 2018 Edition will be stabilized/finalized at some point in the next few months. This issue is meant to be a tracking issue to determine what support is available for Rust 2018 in OS's supported by Suricata, to determine when it is appropriate to move to 2018 edition.

More information on editions: https://rust-lang-nursery.github.io/edition-guide/editions/index.html
Rust 2018 RC Milestone: https://github.com/rust-lang/rust/milestone/54
Rust 2018 Release Milestone: https://github.com/rust-lang/rust/milestone/55
Rust 2018 Tracking Issue: https://internals.rust-lang.org/t/rust-2018-the-home-stretch/7810

Current target is 10/25 for Rust 2018 (Rust 1.30)

One of the most significant changes for 2018 is changes to how crates, modules, and macros are found. Although much easier to use, this will produce a bit of churn in the Suricata rust code. Commit representing the churn involved: https://github.com/dbcfd/suricata/commit/33694e63dbbfc221ffda2882727b4fe431d9375e

The borrow checker has been improved as well, so some things that were safe before but compiler errors will now work with the NLL based borrow checker. Other things that may have worked but were unsafe should now be caught.

OS/Distribution Version Rust Version Supported Notes
CentOS 6 -- No Rust can be install manually
CentOS 7 1.35.0 Yes Requires EPEL
Debian 9 1.24.1 Yes will be EOL ~2020, in LTS state until ~2022 (https://wiki.debian.org/DebianReleases)
Debian 10 1.34.2 Yes
Fedora 28+ 1.31.0 Yes
Ubuntu 14.04 1.31.0 Yes Will be EOL before Suricata 5
Ubuntu 16.04 1.32.0 Yes
Ubuntu 18.04 1.32.0 Yes
FreeBSD 11.2 1.33.0 Yes pkg install rustc cargo
FreeBSD 12.0 1.33.0 Yes pkg install rustc cargo
OpenBSD 6.4 1.29.2 Yes Rust is in ports; next OpenBSD will have 1.33+
MinGW ?? 1.35.0 ?? Can be installed through pacman

Related issues

Related to Feature #2507: Make Rust mandatoryClosedActions

History

#1

Updated by Jason Ish 10 months ago

#2

Updated by Danny Browning 8 months ago

Rust 2018 (version 1.31.0) will be available 12/6

#3

Updated by Jason Ish 8 months ago

Danny Browning wrote:

One of the most significant changes for 2018 is changes to how crates, modules, and macros are found. Although much easier to use, this will produce a bit of churn in the Suricata rust code. Commit representing the churn involved: https://github.com/dbcfd/suricata/commit/33694e63dbbfc221ffda2882727b4fe431d9375e

I wonder if any of these changes can be made while also support Rust 1.24.1, the oldest we currently should still support?

#4

Updated by Danny Browning 8 months ago

I'm hoping that minimum version will go higher with the release of 2018 edition. But after making the 2018 edition changes, I will attempt with older compiler versions (up to 1.24.1) and see at what version it breaks.

#5

Updated by Danny Browning 7 months ago

Rust 1.30.0 is the first rust version that supports the edition keyword.

#6

Updated by Danny Browning 7 months ago

Rust 1.31.0 is the first rust version that edition is stable in.

#7

Updated by Danny Browning 7 months ago

When using `cargo fix --edition` the first rustc that will work is 1.30.0. If we want to enable edition features, users needs 1.31.0.

#8

Updated by Danny Browning 7 months ago

PR indiating required changes: https://github.com/OISF/suricata/pull/3604

#9

Updated by Victor Julien 4 months ago

  • Assignee set to OISF Dev
#10

Updated by Jason Ish 3 months ago

  • Description updated (diff)

Copied in the Rust version chart from #2507. I think its useful for noting which distributions support Rust 2018.

#11

Updated by Andreas Herz about 1 month ago

  • Target version set to TBD
#12

Updated by Victor Julien about 1 month ago

  • Description updated (diff)
#13

Updated by Victor Julien 10 days ago

  • Description updated (diff)
#14

Updated by Victor Julien 10 days ago

  • Description updated (diff)
#15

Updated by Victor Julien 10 days ago

With Debian 10s release Rust 2018 is available on all major distros. We do need to decide how long Debian 9 remains important. We know that no 5.0 will be made available for it through its own channels, so the question is if/when we think its reasonable to either push ppl to 10 or to tell them to install Rust from other channels like rustup.

#16

Updated by Jason Ish 9 days ago

Victor Julien wrote:

With Debian 10s release Rust 2018 is available on all major distros. We do need to decide how long Debian 9 remains important. We know that no 5.0 will be made available for it through its own channels, so the question is if/when we think its reasonable to either push ppl to 10 or to tell them to install Rust from other channels like rustup.

If it will never be made available through proper Debian channels, I'm of the opinion we don't have to worry about it.

Also available in: Atom PDF