xbps-src: new layout in masterdir to use a common directory from host.

XBPS_CACHEDIR has been replaced by XBPS_HOSTDIR in configuration file,
and this expects the following structure:

/host
  |_ /build (previously /pkg-builddir)
  |_ /binpkgs (previously /pkg-binpkgs)
  |_ /repocache (previously /cachedir)
  |_ /sources (previously /pkg-srcdistdir)

Thanks to str1ngs for the great idea!
This commit is contained in:
Juan RP
2011-07-08 02:07:38 +02:00
parent c335a73af5
commit b6c21b960b
5 changed files with 40 additions and 37 deletions

View File

@@ -25,7 +25,7 @@
_mount()
{
MASTERDIR="${XBPS_MASTERDIR}" CACHEDIR="${XBPS_CACHEDIR}" \
MASTERDIR="${XBPS_MASTERDIR}" HOSTDIR="${XBPS_HOSTDIR}" \
${sudo_cmd} \
@@XBPS_INSTALL_LIBEXECDIR@@/xbps-src-chroot-helper mount
return $?
@@ -33,7 +33,7 @@ _mount()
_umount()
{
MASTERDIR="${XBPS_MASTERDIR}" CACHEDIR="${XBPS_CACHEDIR}" \
MASTERDIR="${XBPS_MASTERDIR}" HOSTDIR="${XBPS_HOSTDIR}" \
${sudo_cmd} \
@@XBPS_INSTALL_LIBEXECDIR@@/xbps-src-chroot-helper umount
return $?
@@ -86,8 +86,8 @@ _EOF
if [ -n "$XBPS_COMPRESS_LEVEL" ]; then
echo "XBPS_COMPRESS_LEVEL=$XBPS_COMPRESS_LEVEL" >> $XBPSSRC_CF
fi
if [ -n "$XBPS_CACHEDIR" ]; then
echo "XBPS_CACHEDIR=/cachedir" >> $XBPSSRC_CF
if [ -n "$XBPS_HOSTDIR" ]; then
echo "XBPS_HOSTDIR=/host" >> $XBPSSRC_CF
fi
echo "# End of configuration file." >> $XBPSSRC_CF