LinkerFlavor::Gcc defaults to cc, not gcc

This commit is contained in:
Jorge Aparicio 2018-08-19 09:39:19 +02:00
parent 4bbedd7dd2
commit c8ef8b6602

View File

@ -606,7 +606,7 @@ pub fn linker_and_flavor(sess: &Session) -> (PathBuf, LinkerFlavor) {
// only the linker flavor is known; use the default linker for the selected flavor // only the linker flavor is known; use the default linker for the selected flavor
(None, Some(flavor)) => Some((PathBuf::from(match flavor { (None, Some(flavor)) => Some((PathBuf::from(match flavor {
LinkerFlavor::Em => if cfg!(windows) { "emcc.bat" } else { "emcc" }, LinkerFlavor::Em => if cfg!(windows) { "emcc.bat" } else { "emcc" },
LinkerFlavor::Gcc => "gcc", LinkerFlavor::Gcc => "cc",
LinkerFlavor::Ld => "ld", LinkerFlavor::Ld => "ld",
LinkerFlavor::Msvc => "link.exe", LinkerFlavor::Msvc => "link.exe",
LinkerFlavor::Lld(_) => "lld", LinkerFlavor::Lld(_) => "lld",