common: remove unneccessary 'source's; move extglob.sh to install

This commit is contained in:
Enno Boland 2015-11-18 10:00:56 +01:00
parent ef24b7b7cc
commit 18e288fd2c
4 changed files with 16 additions and 21 deletions

View file

@ -0,0 +1,15 @@
# This provides the extglob function to expand wildcards in the destdir
expand_destdir() {
local glob_list= result= glob= file=
for glob; do
glob_list+=" $DESTDIR/$glob"
done
shopt -s extglob
for file in $glob_list; do
result+=" ${file#$DESTDIR/}"
done
shopt -u extglob
echo $result
}

View file

@ -1,17 +0,0 @@
# This provides the extglob function to expand wildcards in the destdir
expand_destdir() {
local glob_list= result= glob= file=
for glob; do
glob_list+=" $DESTDIR/$glob"
done
shopt -s extglob
for file in $glob_list; do
result+=" ${file#$DESTDIR/}"
done
shopt -u extglob
echo $result
}

View file

@ -0,0 +1 @@
../install/extglob.sh

View file

@ -1,7 +1,5 @@
# This hook generates a XBPS binary package from an installed package in destdir.
source ${XBPS_COMMONDIR}/environment/pkg/extglob.sh
genpkg() {
local pkgdir="$1" arch="$2" desc="$3" pkgver="$4" binpkg="$5"
local _preserve _deps _shprovides _shrequires _gitrevs _provides _conflicts

View file

@ -1,7 +1,5 @@
# This hook checks for common issues related to void.
source ${XBPS_COMMONDIR}/environment/pkg/extglob.sh
hook() {
local error=0 filename= rev= libname= conflictPkg= conflictFile=
local conflictRev= ignore= found= mapshlibs=$XBPS_COMMONDIR/shlibs