From 4f708ca261d9863e2ce0477ae4ed6fb06615b9bf Mon Sep 17 00:00:00 2001 From: Doan Tran Cong Danh Date: Fri, 25 Oct 2019 10:30:37 +0700 Subject: [PATCH] base-files: prefer /usr/local/bin to /usr/bin Fix #15781 --- srcpkgs/base-files/files/profile | 23 +++++++---------------- srcpkgs/base-files/template | 2 +- 2 files changed, 8 insertions(+), 17 deletions(-) diff --git a/srcpkgs/base-files/files/profile b/srcpkgs/base-files/files/profile index 947aeada566..9779832dd27 100644 --- a/srcpkgs/base-files/files/profile +++ b/srcpkgs/base-files/files/profile @@ -2,23 +2,14 @@ # System wide environment and startup programs. -appendpath () { - case ":$PATH:" in - *:"$1":*) - ;; - *) - PATH="${PATH:+$PATH:}$1" - esac -} - # Set our default path (/usr/sbin:/sbin:/bin included for non-Void chroots) -appendpath '/usr/local/sbin' -appendpath '/usr/local/bin' -appendpath '/usr/bin' -appendpath '/usr/sbin' -appendpath '/sbin' -appendpath '/bin' -unset appendpath +VOID_PATH="/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin" +case ":$PATH:" in + *:$VOID_PATH:*) ;; + *) + PATH="$VOID_PATH${PATH:+:$PATH}" ;; +esac +unset VOID_PATH export PATH diff --git a/srcpkgs/base-files/template b/srcpkgs/base-files/template index a049c59681d..0c517253b23 100644 --- a/srcpkgs/base-files/template +++ b/srcpkgs/base-files/template @@ -1,7 +1,7 @@ # Template file for 'base-files' pkgname=base-files version=0.140 -revision=8 +revision=9 bootstrap=yes depends="xbps-triggers" short_desc="Void Linux base system files"