MOCKSTACKS
EN
Questions And Answers

More Tutorials








Rust Installation

In this section you will learn how to install Rust on Windows as well as Linux/Mac.

Installing Rust on Windows

Setup will consist of 3 steps for installation and 3 steps for verification

Install Visual studio Or C++ 2013 or higher

First you will need to download and install Visual Studio 2013 express edition from this link Click Here

Download rustup

Next you will need to download rustup-init.exe from this link Click Here

Install rustup

After you downloaded rustup-init.exe run the exe file and choose default installation option number 1

Verify Files

Next navigate to folder C:\Users\{PC}\.cargo\bin you should see below files

cargo-fmt.exe
cargo.exe
rls.exe
rust-gdb.exe
rust-lldb.exe
rustc.exe
rustdoc.exe
rustfmt.exe
rustup.exe

Verify cargo

Open command Prompt cmd and type below command and verify output

C:\Users\Admin>cargo -V
cargo 1.29.0 (524a578d7 2018-08-05)

Verify rustc

Open command Prompt cmd and type below command and verify output

C:\Users\Admin>rustc --version
rustc 1.29.0 (aa3ca1994 2018-09-11)



Installing Rust on Linux/Mac

Setup will consist of 2 steps for installation

Install rustup

From your terminal install rustup using below command

$ curl https://sh.rustup.rs -sSf | sh

Export Environment variables

Once you installed rustup, like many programming lanaguages, you need to to export environment variables to you system PATH by executing below command:

$ source $HOME/.cargo/env





Conclusion

In this page (written and validated by ) you learned about Rust Installation . What's Next? If you are interested in completing Rust tutorial, your next topic will be learning about: Rust Output Function - println.



Incorrect info or code snippet? We take very seriously the accuracy of the information provided on our website. We also make sure to test all snippets and examples provided for each section. If you find any incorrect information, please send us an email about the issue: mockstacks@gmail.com.


Share On:


Mockstacks was launched to help beginners learn programming languages; the site is optimized with no Ads as, Ads might slow down the performance. We also don't track any personal information; we also don't collect any kind of data unless the user provided us a corrected information. Almost all examples have been tested. Tutorials, references, and examples are constantly reviewed to avoid errors, but we cannot warrant full correctness of all content. By using Mockstacks.com, you agree to have read and accepted our terms of use, cookies and privacy policy.