rpathing is based on the target, not host OS

This commit is contained in:
Brian Anderson 2011-10-06 13:11:56 -07:00
parent d8a85f0758
commit 062ba22d99

View file

@ -13,9 +13,12 @@ import util::filesearch;
// to be exported
export get_rpath_flags, test;
#[cfg(target_os="linux")]
#[cfg(target_os="macos")]
fn get_rpath_flags(sess: session::session, out_filename: str) -> [str] {
// No rpath on windows
if sess.get_targ_cfg().os == session::os_win32 {
ret [];
}
log "preparing the RPATH!";
let cwd = os::getcwd();
@ -31,11 +34,6 @@ fn get_rpath_flags(sess: session::session, out_filename: str) -> [str] {
rpaths_to_flags(rpaths)
}
#[cfg(target_os="win32")]
fn get_rpath_flags(_sess: session::session, _out_filename: str) -> [str] {
[]
}
fn get_sysroot_absolute_rt_lib(sess: session::session) -> fs::path {
let path = [sess.filesearch().sysroot()]
+ filesearch::relative_target_lib_path(