You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Decided to try rust tonight. Can't get even hello world compiled. I tried searching but there's lot's of similar reports and most of them marked as resolved?
C:\Users\Oliver\dev\rust-hello>rustc main.rs
error: linking with `C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\amd64\link.exe` failed: exit code: 1181
|
= note: "C:\\Program Files (x86)\\Microsoft Visual Studio 12.0\\VC\\bin\\amd64\\link.exe" "/NOLOGO" "/NXCOMPAT" "/LIBPATH:C:\\Users\\Oliver\\.rustup\\toolchains\\stable-x86_64-pc-windows-msvc\\lib\\rustlib\\x86_64-pc-windows-msvc\\lib" "main.main0.rcgu.o" "main.main1.rcgu.o" "main.main2.rcgu.o" "main.main3.rcgu.o" "/OUT:main.exe" "main.crate.allocator.rcgu.o" "/OPT:REF,NOICF" "/DEBUG" "/NATVIS:C:\\Users\\Oliver\\.rustup\\toolchains\\stable-x86_64-pc-windows-msvc\\lib\\rustlib\\etc\\intrinsic.natvis" "/NATVIS:C:\\Users\\Oliver\\.rustup\\toolchains\\stable-x86_64-pc-windows-msvc\\lib\\rustlib\\etc\\liballoc.natvis" "/NATVIS:C:\\Users\\Oliver\\.rustup\\toolchains\\stable-x86_64-pc-windows-msvc\\lib\\rustlib\\etc\\libcore.natvis" "/LIBPATH:C:\\Users\\Oliver\\.rustup\\toolchains\\stable-x86_64-pc-windows-msvc\\lib\\rustlib\\x86_64-pc-windows-msvc\\lib" "C:\\Users\\Oliver\\.rustup\\toolchains\\stable-x86_64-pc-windows-msvc\\lib\\rustlib\\x86_64-pc-windows-msvc\\lib\\libstd-7448a93a40cf2c3f.rlib" "C:\\Users\\Oliver\\.rustup\\toolchains\\stable-x86_64-pc-windows-msvc\\lib\\rustlib\\x86_64-pc-windows-msvc\\lib\\libpanic_unwind-1eb9a4cd8388f802.rlib" "C:\\Users\\Oliver\\.rustup\\toolchains\\stable-x86_64-pc-windows-msvc\\lib\\rustlib\\x86_64-pc-windows-msvc\\lib\\libunwind-ffbf31c50cb70f99.rlib" "C:\\Users\\Oliver\\.rustup\\toolchains\\stable-x86_64-pc-windows-msvc\\lib\\rustlib\\x86_64-pc-windows-msvc\\lib\\liblibc-49f242c4944f2f4b.rlib" "C:\\Users\\Oliver\\.rustup\\toolchains\\stable-x86_64-pc-windows-msvc\\lib\\rustlib\\x86_64-pc-windows-msvc\\lib\\liballoc_system-4fc81c8f97d71835.rlib" "C:\\Users\\Oliver\\.rustup\\toolchains\\stable-x86_64-pc-windows-msvc\\lib\\rustlib\\x86_64-pc-windows-msvc\\lib\\liballoc-85d92121f1ed0b0c.rlib" "C:\\Users\\Oliver\\.rustup\\toolchains\\stable-x86_64-pc-windows-msvc\\lib\\rustlib\\x86_64-pc-windows-msvc\\lib\\libstd_unicode-63f640f34ce6d9b1.rlib" "C:\\Users\\Oliver\\.rustup\\toolchains\\stable-x86_64-pc-windows-msvc\\lib\\rustlib\\x86_64-pc-windows-msvc\\lib\\libcore-e2f4c2f8ebed02cb.rlib" "C:\\Users\\Oliver\\.rustup\\toolchains\\stable-x86_64-pc-windows-msvc\\lib\\rustlib\\x86_64-pc-windows-msvc\\lib\\libcompiler_builtins-c4ca9f329f3bf160.rlib" "advapi32.lib" "ws2_32.lib" "userenv.lib" "shell32.lib" "msvcrt.lib"
= note: LINK : warning LNK4044: unrecognized option '/NATVIS:C:\Users\Oliver\.rustup\toolchains\stable-x86_64-pc-windows-msvc\lib\rustlib\etc\intrinsic.natvis'; ignored
LINK : warning LNK4044: unrecognized option '/NATVIS:C:\Users\Oliver\.rustup\toolchains\stable-x86_64-pc-windows-msvc\lib\rustlib\etc\liballoc.natvis'; ignored
LINK : warning LNK4044: unrecognized option '/NATVIS:C:\Users\Oliver\.rustup\toolchains\stable-x86_64-pc-windows-msvc\lib\rustlib\etc\libcore.natvis'; ignored
LINK : fatal error LNK1181: cannot open input file 'advapi32.lib'
error: aborting due to previous error
The text was updated successfully, but these errors were encountered:
The warnings about /NATVIS are because the linker from VS 2013 doesn't yet support them, but that should be harmless. I do recommend upgrading of course, but it's not strictly necessary in this case.
The error about being unable to find advapi32.lib is because rustc is able to find link.exe in your PATH but you don't have LIB configured with the Windows SDK library directories, so link.exe is unable to find any of the necessary system libraries such as advapi32.lib. Ensure you have the Windows SDK installed and that your environment variables are configured correctly.
Hello.
Decided to try rust tonight. Can't get even hello world compiled. I tried searching but there's lot's of similar reports and most of them marked as resolved?
The text was updated successfully, but these errors were encountered: