Rollup merge of #85361 - bjorn3:rustdoc_target_json_path_canonicalize, r=jyn514
Use TargetTriple::from_path in rustdoc This fixes the problem reported in https://github.com/Rust-for-Linux/linux/pull/272 where rustdoc requires the absolute path of a target spec json instead of accepting a relative path like rustc.
This commit is contained in:
commit
6b0b81b098
6 changed files with 62 additions and 11 deletions
|
@ -1507,7 +1507,10 @@ fn collect_print_requests(
|
|||
prints
|
||||
}
|
||||
|
||||
fn parse_target_triple(matches: &getopts::Matches, error_format: ErrorOutputType) -> TargetTriple {
|
||||
pub fn parse_target_triple(
|
||||
matches: &getopts::Matches,
|
||||
error_format: ErrorOutputType,
|
||||
) -> TargetTriple {
|
||||
match matches.opt_str("target") {
|
||||
Some(target) if target.ends_with(".json") => {
|
||||
let path = Path::new(&target);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue