Lines Matching full:clang
19 /// A `clang` executable.
21 pub struct Clang { struct
22 /// The path to this `clang` executable.
24 /// The version of this `clang` executable if it could be parsed.
26 /// The directories searched by this `clang` executable for C headers if
29 /// The directories searched by this `clang` executable for C++ headers if
34 impl Clang { argument
44 /// Returns a `clang` executable if one can be found.
47 /// `clang` used. Otherwise, a series of directories are searched. First, if
50 /// systems, `xcodebuild -find clang` will next be queried. Last, the
57 /// target-prefixed instance of `clang` (e.g.,
58 /// `x86_64-unknown-linux-gnu-clang` for the above example).
59 pub fn find(path: Option<&Path>, args: &[String]) -> Option<Clang> { in find() argument
63 return Some(Clang::new(p, args)); in find()
76 // Collect the paths to search for a `clang` executable in. in find()
91 if let Ok((path, _)) = run("xcodebuild", &["-find", "clang"]) { in find()
102 // First, look for a target-prefixed `clang` executable. in find()
105 let default = format!("{}-clang{}", target, env::consts::EXE_SUFFIX); in find()
106 let versioned = format!("{}-clang-[0-9]*{}", target, env::consts::EXE_SUFFIX); in find()
110 return Some(Clang::new(path, args)); in find()
115 // Otherwise, look for any other `clang` executable. in find()
117 let default = format!("clang{}", env::consts::EXE_SUFFIX); in find()
118 let versioned = format!("clang-[0-9]*{}", env::consts::EXE_SUFFIX); in find()
122 return Some(Clang::new(path, args)); in find()
185 /// Runs `clang`, returning the `stdout` and `stderr` output.
206 /// Parses the version from the output of a `clang` executable if possible.
221 /// Parses the search paths from the output of a `clang` executable if possible.