{"action":"created","issue":{"url":"https://api.github.com/repos/rust-lang/rust/issues/41664","repository_url":"https://api.github.com/repos/rust-lang/rust","labels_url":"https://api.github.com/repos/rust-lang/rust/issues/41664/labels{/name}","comments_url":"https://api.github.com/repos/rust-lang/rust/issues/41664/comments","events_url":"https://api.github.com/repos/rust-lang/rust/issues/41664/events","html_url":"https://github.com/rust-lang/rust/issues/41664","id":225360831,"number":41664,"title":"Invalid linker command line: double LIBPATH arg","user":{"login":"Andriy06","id":13165215,"avatar_url":"https://avatars1.githubusercontent.com/u/13165215?v=3","gravatar_id":"","url":"https://api.github.com/users/Andriy06","html_url":"https://github.com/Andriy06","followers_url":"https://api.github.com/users/Andriy06/followers","following_url":"https://api.github.com/users/Andriy06/following{/other_user}","gists_url":"https://api.github.com/users/Andriy06/gists{/gist_id}","starred_url":"https://api.github.com/users/Andriy06/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Andriy06/subscriptions","organizations_url":"https://api.github.com/users/Andriy06/orgs","repos_url":"https://api.github.com/users/Andriy06/repos","events_url":"https://api.github.com/users/Andriy06/events{/privacy}","received_events_url":"https://api.github.com/users/Andriy06/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2017-04-30T22:59:40Z","updated_at":"2017-05-01T00:20:22Z","closed_at":"2017-05-01T00:20:22Z","body":"I installed Rust on Windows 10 machine by rustup-init.exe - the method recommended in Rust Book. The installer told me that Rust needs C-runtime of VS2013 or newer. I have VS2017 installed, I assumed Rust doesn't support VS2017 yet and so agreed to install C-runtime. Installation finished successfully.\r\n\r\nmain.rs:\r\n\r\n```\r\nfn main() {\r\n    println!(\"Hello, world!\");\r\n}\r\n```\r\nCompiling:\r\n\r\n```\r\n> rustc main.rs\r\nerror: linking with `link.exe` failed: exit code: 1\r\n  |\r\n  = note: \"link.exe\" \"/NOLOGO\" \"/NXCOMPAT\" \"/LIBPATH:C:\\\\Users\\\\***\\\\.rustup\\\\toolchains\\\\stable-x86_64-pc-windows-msvc\\\\lib\\\\rustlib\\\\x86_64-pc-windows-msvc\\\\lib\" \"main.0.o\" \"/OUT:main.exe\" \"/OPT:REF,NOICF\" \"/DEBUG\" \"/LIBPATH:C:\\\\Users\\\\***\\\\.rustup\\\\toolchains\\\\stable-x86_64-pc-windows-msvc\\\\lib\\\\rustlib\\\\x86_64-pc-windows-msvc\\\\lib\" \"C:\\\\Users\\\\***\\\\.rustup\\\\toolchains\\\\stable-x86_64-pc-windows-msvc\\\\lib\\\\rustlib\\\\x86_64-pc-windows-msvc\\\\lib\\\\libstd-0a78323911070f99.rlib\" \"C:\\\\Users\\\\***\\\\.rustup\\\\toolchains\\\\stable-x86_64-pc-windows-msvc\\\\lib\\\\rustlib\\\\x86_64-pc-windows-msvc\\\\lib\\\\librand-c279a51d66700350.rlib\" \"C:\\\\Users\\\\***\\\\.rustup\\\\toolchains\\\\stable-x86_64-pc-windows-msvc\\\\lib\\\\rustlib\\\\x86_64-pc-windows-msvc\\\\lib\\\\libcollections-d7bf31a4ca1ea637.rlib\" \"C:\\\\Users\\\\***\\\\.rustup\\\\toolchains\\\\stable-x86_64-pc-windows-msvc\\\\lib\\\\rustlib\\\\x86_64-pc-windows-msvc\\\\lib\\\\libstd_unicode-d367c3ba0db49600.rlib\" \"C:\\\\Users\\\\***\\\\.rustup\\\\toolchains\\\\stable-x86_64-pc-windows-msvc\\\\lib\\\\rustlib\\\\x86_64-pc-windows-msvc\\\\lib\\\\libpanic_unwind-2d4bf02140c11dcb.rlib\" \"C:\\\\Users\\\\***\\\\.rustup\\\\toolchains\\\\stable-x86_64-pc-windows-msvc\\\\lib\\\\rustlib\\\\x86_64-pc-windows-msvc\\\\lib\\\\libunwind-add7a84d7e82d084.rlib\" \"C:\\\\Users\\\\***\\\\.rustup\\\\toolchains\\\\stable-x86_64-pc-windows-msvc\\\\lib\\\\rustlib\\\\x86_64-pc-windows-msvc\\\\lib\\\\liblibc-84688accbc86d6b7.rlib\" \"C:\\\\Users\\\\***\\\\.rustup\\\\toolchains\\\\stable-x86_64-pc-windows-msvc\\\\lib\\\\rustlib\\\\x86_64-pc-windows-msvc\\\\lib\\\\liballoc-fe2e68b21f0bdd7a.rlib\" \"C:\\\\Users\\\\***\\\\.rustup\\\\toolchains\\\\stable-x86_64-pc-windows-msvc\\\\lib\\\\rustlib\\\\x86_64-pc-windows-msvc\\\\lib\\\\liballoc_system-7fc0381594c93f56.rlib\" \"C:\\\\Users\\\\***\\\\.rustup\\\\toolchains\\\\stable-x86_64-pc-windows-msvc\\\\lib\\\\rustlib\\\\x86_64-pc-windows-msvc\\\\lib\\\\libcore-ea9d77e7c23fe65c.rlib\" \"C:\\\\Users\\\\***\\\\.rustup\\\\toolchains\\\\stable-x86_64-pc-windows-msvc\\\\lib\\\\rustlib\\\\x86_64-pc-windows-msvc\\\\lib\\\\libcompiler_builtins-91b619d34dd1f5aa.rlib\" \"advapi32.lib\" \"ws2_32.lib\" \"userenv.lib\" \"shell32.lib\" \"msvcrt.lib\"\r\n  = note: /usr/bin/link: extra operand '/LIBPATH:C:\\\\Users\\\\***\\\\.rustup\\\\toolchains\\\\stable-x86_64-pc-windows-msvc\\\\lib\\\\rustlib\\\\x86_64-pc-windows-msvc\\\\lib'\r\n          Try '/usr/bin/link --help' for more information.\r\n\r\nerror: aborting due to previous error\r\n```\r\nlink.exe LIBPATH arg is specified twice.\r\n\r\n```\r\n> rustc --version\r\nrustc 1.17.0 (56124baa9 2017-04-24)\r\n```"},"comment":{"url":"https://api.github.com/repos/rust-lang/rust/issues/comments/298266890","html_url":"https://github.com/rust-lang/rust/issues/41664#issuecomment-298266890","issue_url":"https://api.github.com/repos/rust-lang/rust/issues/41664","id":298266890,"user":{"login":"retep998","id":666308,"avatar_url":"https://avatars2.githubusercontent.com/u/666308?v=3","gravatar_id":"","url":"https://api.github.com/users/retep998","html_url":"https://github.com/retep998","followers_url":"https://api.github.com/users/retep998/followers","following_url":"https://api.github.com/users/retep998/following{/other_user}","gists_url":"https://api.github.com/users/retep998/gists{/gist_id}","starred_url":"https://api.github.com/users/retep998/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/retep998/subscriptions","organizations_url":"https://api.github.com/users/retep998/orgs","repos_url":"https://api.github.com/users/retep998/repos","events_url":"https://api.github.com/users/retep998/events{/privacy}","received_events_url":"https://api.github.com/users/retep998/received_events","type":"User","site_admin":false},"created_at":"2017-05-01T00:20:22Z","updated_at":"2017-05-01T00:20:22Z","body":"Notice this key part `/usr/bin/link`. That is not `link.exe` from msvc, but rather from some MinGW installation you have on your computer. This means rustc is simply failing to autodetect your VS 2017 installation and is blindly invoking `link.exe` which fails with a confusing error.\r\n\r\nDuplicate of https://github.com/rust-lang/rust/issues/38584 "}}
{"actor":{"display_login":"retep998"}}