abinfo "Enabling Rust backtrace ..."
export RUST_BACKTRACE=1

abinfo "Building Rustc ..."
python3 "$SRCDIR"/x.py dist

abinfo "Installing Rustc ..."
DESTDIR="$PKGDIR" \
    python3 "$SRCDIR"/x.py install

abinfo "Arch Linux: Deleting unnecesary files, e.g. components and manifest files only used for the uninstall script..."
(
    cd "$PKGDIR"/usr/lib/rustlib
    rm -v \
        components \
        install.log \
        manifest-* \
        rust-installer-version \
        uninstall.sh
)
