xbps-src: replace basename(1) with ${var##*/}.
Reduce number of fork+exec due to using a subshell to execute basename(1).
This commit is contained in:
parent
ea9c012c04
commit
bcdacb66a0
20 changed files with 28 additions and 23 deletions
|
@ -182,7 +182,7 @@ run_pkg_hooks() {
|
|||
eval unset -f hook
|
||||
for f in ${XBPS_COMMONDIR}/hooks/${phase}/*.sh; do
|
||||
[ ! -r $f ] && continue
|
||||
hookn=$(basename $f)
|
||||
hookn=${f##*/}
|
||||
hookn=${hookn%.sh}
|
||||
. $f
|
||||
run_func hook "$phase hook: $hookn" ${phase}_${hookn}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue