bytecodealliance / bytecodealliance/rustix

stop enabling dependencies in build.rs by default?

Offen
#680 15 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
Vorherrschende Sprache
Rust
Sterne
2.1k
Forks
294
Ø Merge
4 Std. 7 Min.
Gemergte PRs (30 T.)
2

Beschreibung

(I'm basically using issues as a communication mechanism here)

See https://github.com/coreos/cargo-vendor-filterer/issues/71

TL;DR when rustix 0.37 came along with https://github.com/bytecodealliance/rustix/commit/a2c6c7a8b7adcf46592b7519ba90ecece18b4bd6 this ended up enabling `libc` by default and that pulled in the `errno` dependency by default.

However, `cargo metadata` doesn't see this dependency, it's only enabled via `build.rs`.

And that ends up breaking `cargo vendor-filterer`.

Since in reality, libc is enabled by default, ISTM we can rework the features and build scripts here right?

Beitragsleitfaden

Beitragsleitfaden öffnen

Rechercherichtung

Start by reviewing build.rs and the feature definitions that enable libc and errno, then compare the dependency graph reported by cargo metadata with cargo vendor-filterer behavior. The issue is resolved when the default dependency configuration is represented consistently without build.rs-only activation and cargo vendor-filterer no longer breaks.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
rust
Bereich
build-system
Issue-Typ
Refactoring
Schwierigkeit
4/5
Geschätzter Aufwand
3-5 Tage
Aktivitätsstatus
Veraltet
Klarheit
Muss geklärt werden
Anfängerfreundlichkeit
35/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.