Adapt llvm-has-rust-patches
validation to take llvm-config
into account.
This commit is contained in:
parent
5f40394baa
commit
fd470e58c2
@ -1810,10 +1810,9 @@ fn get_table(option: &str) -> Result<TomlConfig, toml::de::Error> {
|
||||
target.llvm_config = Some(config.src.join(s));
|
||||
}
|
||||
if let Some(patches) = cfg.llvm_has_rust_patches {
|
||||
assert_eq!(
|
||||
config.submodules,
|
||||
Some(false),
|
||||
"cannot set `llvm-has-rust-patches` for a managed submodule (set `build.submodules = false` if you want to apply patches)"
|
||||
assert!(
|
||||
config.submodules == Some(false) || cfg.llvm_config.is_some(),
|
||||
"use of `llvm-has-rust-patches` is restricted to cases where either submodules are disabled or llvm-config been provided"
|
||||
);
|
||||
target.llvm_has_rust_patches = Some(patches);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user