about summary refs log tree commit diff
path: root/src/librustc
diff options
context:
space:
mode:
Diffstat (limited to 'src/librustc')
-rw-r--r--src/librustc/session/filesearch.rs7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/librustc/session/filesearch.rs b/src/librustc/session/filesearch.rs
index c204556d517..8c72869eb12 100644
--- a/src/librustc/session/filesearch.rs
+++ b/src/librustc/session/filesearch.rs
@@ -124,6 +124,13 @@ pub fn make_target_lib_path(sysroot: &Path, target_triple: &str) -> PathBuf {
     sysroot.join(&relative_target_lib_path(sysroot, target_triple))
 }
 
+pub fn target_lib_path(target_triple: &str) -> PathBuf {
+    let mut p = PathBuf::from(RUST_LIB_DIR);
+    p.push(target_triple);
+    p.push("lib");
+    p
+}
+
 pub fn get_or_default_sysroot() -> PathBuf {
     // Follow symlinks.  If the resolved path is relative, make it absolute.
     fn canonicalize(path: Option<PathBuf>) -> Option<PathBuf> {