Added support to build pkgs in the chroot as normal user via capchroot.
Please read the comment in xbps-src.conf to use it. Fully tested and working nicely, probably some pkgs will need minimal changes. --HG-- extra : convert_revision : 820ad6d48aa74cf5b6db1871adea750acccaa82f
This commit is contained in:
parent
5d6d7b0f4e
commit
e57940985e
15 changed files with 406 additions and 242 deletions
|
@ -56,7 +56,7 @@ binpkg_cleanup()
|
|||
#
|
||||
xbps_make_binpkg_real()
|
||||
{
|
||||
local mfiles binpkg pkgdir arch use_sudo lver dirs _dirs d clevel
|
||||
local mfiles binpkg pkgdir arch lver dirs _dirs d clevel
|
||||
|
||||
if [ ! -d "${DESTDIR}" ]; then
|
||||
msg_warn "cannot find destdir for $pkgname... skipping!"
|
||||
|
@ -69,11 +69,6 @@ xbps_make_binpkg_real()
|
|||
else
|
||||
arch=$xbps_machine
|
||||
fi
|
||||
if [ -n "$base_chroot" ]; then
|
||||
use_sudo=no
|
||||
else
|
||||
use_sudo=yes
|
||||
fi
|
||||
if [ -n "$revision" ]; then
|
||||
lver="${version}_${revision}"
|
||||
else
|
||||
|
@ -116,8 +111,9 @@ xbps_make_binpkg_real()
|
|||
trap "binpkg_cleanup" INT
|
||||
|
||||
echo -n "=> Building $binpkg... "
|
||||
run_rootcmd $use_sudo tar --exclude "var/db/xbps/metadata/*/flist" \
|
||||
-cpf - ${mfiles} ${dirs} | \
|
||||
${fakeroot_cmd} ${fakeroot_cmd_args} \
|
||||
tar --exclude "var/db/xbps/metadata/*/flist" \
|
||||
-cpf - ${mfiles} ${dirs} | \
|
||||
$XBPS_COMPRESS_CMD ${clevel} -qf > $pkgdir/$binpkg
|
||||
if [ $? -eq 0 ]; then
|
||||
echo "done."
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue