![]() ![]() You can compile it with rustc, then run it: Test your installationĬheck that Rust is installed correctly by building a simple program, as follows: You can use gcc, otherwise Rust will generate the following error: linker `cc` not found. Rust does not do its own linking, and so you’ll need to have a linker installed. The script installs and activates the default toolchain by default (the one used by the rust package), so there is no need to manually install it to start using Rust. To update rustup afterwards, run rustup self update. You need to source ~/.cargo/env until you logout and login back into the system. The script makes PATH changes only to login shell configuration files. Rustup is also available to download and install manually via rustup's official web page.ĭownload the file with curl -proto '=https' -tlsv1.3 -sSf -o rust.sh, view it: less. $ rustup default stable Upstream installation script In order to install the toolchain, you need to tell rustup which version to use: stable or nightly. As stated above, the user still needs to install a toolchain manually for these Rust commands to do anything. ![]() It provides instead symlinks between /usr/bin/rustup to the common binaries such as /usr/bin/rustc and /usr/bin/cargo. Note: The rustup package does not install a toolchain by default. This package has the advantage that the various Rust executables live in /usr/bin, instead of ~/.cargo/bin, removing the need to add another directory to your PATH. Note that rustup self update will not work when installed this way, the package needs to be updated by pacman. Rustup is available on the Arch Linux software repository. There are two choices for a Rustup installation, one is supported by Arch Linux via pacman, while the other is officially supported by Rust via their installation script. The benefit of using the Rustup toolchain manager instead of the standalone prepackaged Rust in the software repository is the ability to install multiple toolchains (stable, beta, nightly) for multiple targets (windows, mac, android) and architectures (x86, x86_64, arm). ![]() The official and recommended method of installing Rust for the purpose of developing software is to use the Rustup toolchain manager, written in Rust. There is also a development version of the Rust compiler available: rust-nightly-bin AUR for prebuilt generic binaries or rust-git AUR to build the compiler with system libraries. This will install the rustc compiler and Cargo. To install the latest stable version of Rust from the official Arch Linux software repository, install the rust package.
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |