xbps-src: move ccache/distcc to hostdir, to make them shared by multiple masterdirs.
This way a single ccache or distcc directory can be shared by multiple independent masterdirs.
This commit is contained in:
parent
77642dc2e9
commit
58bbb98712
|
@ -30,8 +30,8 @@ XBPS_SRC_VERSION="$XBPS_SRC_VERSION"
|
|||
|
||||
PATH=/void-packages:/usr/bin:/usr/sbin
|
||||
|
||||
exec env -i PATH="\$PATH" DISTCC_HOSTS="\$XBPS_DISTCC_HOSTS" DISTCC_DIR="/distcc" @@XARCH@@ \
|
||||
CCACHE_DIR="/ccache" IN_CHROOT=1 LANG=en_US.UTF-8 TERM=linux HOME="/tmp" \
|
||||
exec env -i PATH="\$PATH" DISTCC_HOSTS="\$XBPS_DISTCC_HOSTS" DISTCC_DIR="/host/distcc" @@XARCH@@ \
|
||||
CCACHE_DIR="/host/ccache" IN_CHROOT=1 LANG=en_US.UTF-8 TERM=linux HOME="/tmp" \
|
||||
PS1="[\u@$XBPS_MASTERDIR \W]$ " /bin/bash +h
|
||||
_EOF
|
||||
if [ -n "$XBPS_ARCH" ]; then
|
||||
|
|
|
@ -40,12 +40,14 @@ XBPS_LDFLAGS="-Wl,--as-needed"
|
|||
XBPS_SUCMD="sudo /bin/sh -c"
|
||||
|
||||
# [OPTIONAL]
|
||||
# Enable or disable ccache when building packages.
|
||||
# Enable or disable ccache when building packages. The ccache directory
|
||||
# is stored in the hostdir, i.e hostdir/ccache.
|
||||
#
|
||||
#XBPS_CCACHE=yes
|
||||
|
||||
# [OPTIONAL]
|
||||
# Enable or disable distcc when building packages.
|
||||
# Enable or disable distcc when building packages. The distcc directory
|
||||
# is stored in the hostdir, i.e hostdir/distcc.
|
||||
#
|
||||
#XBPS_DISTCC=yes
|
||||
#XBPS_DISTCC_HOSTS=""
|
||||
|
|
16
xbps-src
16
xbps-src
|
@ -485,28 +485,16 @@ else
|
|||
export PATH="$MYPATH"
|
||||
if [ -n "$XBPS_CCACHE" ]; then
|
||||
CCACHEPATH="/usr/lib/ccache/bin"
|
||||
if [ -n "$XBPS_HOSTDIR" -a -d "$XBPS_HOSTDIR/ccache" ]; then
|
||||
export CCACHE_DIR="$XBPS_HOSTDIR/ccache"
|
||||
else
|
||||
if [ ! -d "$XBPS_MASTERDIR/ccache" ]; then
|
||||
mkdir -p $XBPS_MASTERDIR/ccache
|
||||
fi
|
||||
export CCACHE_DIR="$XBPS_MASTERDIR/ccache"
|
||||
fi
|
||||
export PATH="$CCACHEPATH:$PATH"
|
||||
mkdir -p $CCACHE_DIR
|
||||
fi
|
||||
if [ -n "$XBPS_DISTCC" ]; then
|
||||
DISTCCPATH="/usr/lib/distcc/bin"
|
||||
if [ -n "$XBPS_HOSTDIR" -a -d "$XBPS_HOSTDIR/distcc" ]; then
|
||||
export DISTCC_DIR="$XBPS_HOSTDIR/distcc"
|
||||
else
|
||||
if [ ! -d "$XBPS_MASTERDIR/distcc" ]; then
|
||||
mkdir -p $XBPS_MASTERDIR/distcc
|
||||
fi
|
||||
export DISTCC_DIR="$XBPS_MASTERDIR/distcc"
|
||||
fi
|
||||
export DISTCC_HOSTS="$XBPS_DISTCC_HOSTS"
|
||||
export PATH="$DISTCCPATH:$PATH"
|
||||
mkdir -p $DISTCC_DIR
|
||||
fi
|
||||
fi
|
||||
|
||||
|
|
Loading…
Reference in New Issue