File tree Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Original file line number Diff line number Diff line change 223223step_msg " validating $CFG_SELF args"
224224validate_opt
225225
226+ # Sanity check: can we can write to the destination?
227+ touch " ${CFG_PREFIX} /lib/rust-install-probe" 2> /dev/null
228+ if [ $? -ne 0 ]
229+ then
230+ err " can't write to destination. try again with 'sudo'."
231+ fi
232+ rm -r " ${CFG_PREFIX} /lib/rust-install-probe"
233+ need_ok " failed to remove install probe"
234+
235+ # Sanity check: can we run these binaries?
236+ " ${CFG_SRC_DIR} /bin/rustc" --version > /dev/null
237+ need_ok " can't run these binaries on this platform"
238+
226239# First, uninstall from the installation prefix
227240# FIXME: Hardcoded 'rustlib' ignores CFG_RUSTLIBDIR
228241if [ -f " ${CFG_PREFIX} /lib/rustlib/manifest" ]
@@ -262,3 +275,9 @@ while read p; do
262275
263276# The manifest lists all files to install
264277done < " ${CFG_SRC_DIR} /lib/rustlib/manifest"
278+
279+ echo
280+ echo " Rust is ready to roll."
281+ echo
282+
283+
You can’t perform that action at this time.
0 commit comments