xbps-src: base-chroot-v2 (reduce artifacts/deps)

This patchset contains multiple changes to xbps-src and
its required package "base-chroot" for building packages
via chroot.

- moved xbps.d(5) conf files to `etc/xbps.d`.
- renamed xbps.d(5) repository files to `etc/xbps.d/repos-{local,remote}*`.
- do not set `--repository` to any xbps command that supports it,
  xbps-src now simply populates `rootdir/etc/xbps.d` with correct
  settings (taking care of CHROOT_READY/IN_CHROOT).
- Unless `-C` is set (to preserve builddir/destdir/autodeps), when
  entering to the chroot (if CHROOT_READY is set), xbps-src will
  clean up the masterdir and then perform a system update to always
  use a constant set of packages for that exact date.
- Improved some normal/error msgs.
- Includes support for `xbps>=0.58`.
- common/hooks: switch to bsdtar.
- base-chroot:
  - base-chroot-musl is gone, now unified for glibc/musl.
  - deps removed: gettext, mpfr, readline, texinfo, which, xz.
  - deps changed: tar -> bsdtar.

Effectively this reduces dependencies in `base-chroot`, makes
it unified for musl and glibc, switches xbps-src to use `bsdtar`
rather than GNU `tar` and `xz`, gets rid of useless host dependencies
like GNU gettext, texinfo, etc.

I've been testing these changes for 1 month or so already,
I was able to build from scratch `base-system` for both native
and multiple targets, i.e `./xbps-src -a target -Nt pkg base-system`
This commit is contained in:
Juan RP
2020-01-01 11:15:35 +01:00
parent b714ffe390
commit 75eca1b03e
26 changed files with 325 additions and 356 deletions

View File

@@ -15,9 +15,14 @@
#
# [OPTIONAL]
# Enable optional arguments to xbps-install for the host system.
# Currently used in the binary-bootstrap bootstrap-update targets.
XBPS_INSTALL_ARGS="--repository=https://alpha.de.repo.voidlinux.org/current --repository=https://alpha.de.repo.voidlinux.org/current/musl --repository=https://alpha.de.repo.voidlinux.org/current/aarch64"
# Enable optional arguments to xbps-install(1) for the host system.
# Currently used in the 'binary-bootstrap' and 'bootstrap-update' targets.
#
# NOTE: local repositories are handled automatically by xbps-src,
# but you can modify the default remote repositories at
# 'etc/xbps.d/repos-remote*.conf'
#
#XBPS_INSTALL_ARGS=""
# [OPTIONAL]
# Native Compilation/Preprocessor flags for C and C++. Additional settings
@@ -60,7 +65,7 @@ XBPS_SUCMD="sudo /bin/sh -c"
# [OPTIONAL]
# Enable recording git revisions in final binary packages; enable this
# if you are sure the package you are building is available in the
# xbps-packages git repository.
# void-packages git repository.
#
#XBPS_USE_GIT_REVS=yes
@@ -113,8 +118,8 @@ XBPS_SUCMD="sudo /bin/sh -c"
# [OPTIONAL]
# Set the preferred chroot style. Available styles at common/chroot-style/*.sh:
#
# - uunshare (uses xbps-uunshare(8), user namespaces)
# - uchroot (uses xbps-uchroot(8), namespaces, setgid)
# - uunshare (uses xbps-uunshare(1), user namespaces)
# - uchroot (uses xbps-uchroot(1), namespaces, setgid)
# - proot (uses proot, external, does not need special permissions)
# - bwrap (uses bwrap, external, does not need special permissions)
# - ethereal (uses root, needs no permissions, for disposable containers)