Use target-applies-to-host to avoid unnecessary cache invalidation
This commit is contained in:
parent
f158817a7c
commit
3d65c1e957
@ -1,3 +1,13 @@
|
|||||||
|
# Pass the rustflags specified to host dependencies (build scripts, proc-macros)
|
||||||
|
# when a `--target` is passed to Cargo. Historically this was not the case, and
|
||||||
|
# because of that, cross-compilation would not set the rustflags configured
|
||||||
|
# below in `target.'cfg(all())'` for them, resulting in cache invalidation.
|
||||||
|
#
|
||||||
|
# Since this is an unstable feature (enabled at the bottom of the file), this
|
||||||
|
# setting is unfortunately ignored on stable toolchains, but it's still better
|
||||||
|
# to have it apply on nightly than using the old behavior for all toolchains.
|
||||||
|
target-applies-to-host = false
|
||||||
|
|
||||||
[alias]
|
[alias]
|
||||||
xtask = "run --package xtask --"
|
xtask = "run --package xtask --"
|
||||||
|
|
||||||
@ -37,3 +47,8 @@ rustflags = [
|
|||||||
# https://github.com/rust-lang/rust-clippy/issues/8875
|
# https://github.com/rust-lang/rust-clippy/issues/8875
|
||||||
"-Aclippy::derive_partial_eq_without_eq",
|
"-Aclippy::derive_partial_eq_without_eq",
|
||||||
]
|
]
|
||||||
|
|
||||||
|
# activate the target-applies-to-host feature.
|
||||||
|
# Required for `target-applies-to-host` at the top to take effect.
|
||||||
|
[unstable]
|
||||||
|
target-applies-to-host = true
|
||||||
|
Loading…
x
Reference in New Issue
Block a user