Skip to content

Commit

Permalink
login: option to supress 32bit cpu arch warning (#475)
Browse files Browse the repository at this point in the history
  • Loading branch information
huangyxi authored Dec 7, 2024
1 parent 27feedb commit 3ca99dc
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion proot-distro.sh
Original file line number Diff line number Diff line change
Expand Up @@ -1408,6 +1408,7 @@ command_login() {
local no_link2symlink=false
local no_sysvipc=false
local no_kill_on_exit=false
local no_arch_warning=false
local login_user="root"
local login_wd=""
local -a login_env_vars
Expand Down Expand Up @@ -1465,6 +1466,9 @@ command_login() {
--no-kill-on-exit)
no_kill_on_exit=true
;;
--no-arch-warning)
no_arch_warning=true
;;
--user)
if [ $# -ge 2 ]; then
shift 1
Expand Down Expand Up @@ -1790,7 +1794,7 @@ command_login() {
fi
else
# Warn about CPU not supporting 32-bit instructions
if ! $SUPPORT_32BIT; then
if ! $no_arch_warning && ! $SUPPORT_32BIT; then
msg "${BRED}Warning: CPU doesn't support 32-bit instructions, some software may not work.${RST}"
fi
fi
Expand Down Expand Up @@ -2033,6 +2037,9 @@ command_login_help() {
msg " ${CYAN}before exiting. This will cause proot to${RST}"
msg " ${CYAN}freeze if you are running daemons.${RST}"
msg
msg " ${GREEN}--no-arch-warning ${CYAN}- Suppress warning about CPU not supporting 32-bit${RST}"
msg " ${CYAN}instructions.${RST}"
msg
msg " ${GREEN}--kernel [string] ${CYAN}- Set the kernel release and compatibility${RST}"
msg " ${CYAN}level to string.${RST}"
msg
Expand Down

0 comments on commit 3ca99dc

Please sign in to comment.