glibc uses the cross compiler preprocessor to know what architecture
to compile for, resulting in wrong architecture being used with the armv6
cross compiler.
The `etc/defaults.virtual` file contains the default replacement
for our use cases; at this moment we only use it to use `eudev`
rather than `systemd` for udev.
If `etc/virtual` exists it overrides the settings of `etc/defaults.virtual`.
Those helpers were just setting up some extra functions that can be used
on templates, and this can be done already via environment, so let's remove
the helpers completely.
Add the helpers vopt_if, vopt_with and vopt_enable that simplify common
option-based operations.
Instead of a bunch of
if [ "$build_option_foo" ]; then
configure_args+=" --with-foo"
makedepends+=" foo-devel"
else
configure_args+=" --without-foo"
fi
one can use
configure_args="... $(vopt_with foo)
makedepends="... $(vopt_if foo foo-devel)"
instead.
We're adding these functions to common/xbps-src/shutils/common.sh but
that might not be the ideal place. I would've preferred
common/helpers/options.sh, but helpers are only available in the
individual phases, not when the template itself gets parsed.
- There's no need to install rdeps into the masterdir, just base-files.
- There's no need to exit if XBPS_TARGET_PKG == sourcepkg, just return.
- After building base-chroot, install bootstrap binary packages.
The prepare-32bit hook has been moved to the pre-pkg stage and now
those hooks are executed as part of the install phase. That means that
pre-pkg hooks are now independently run for the subpkgs and the sourcepkg
after the install-destdir phase and pre/do/install hooks.
As bonus, finally correct rdeps can now be collected for the 32bit pkgs
and works for all them, without the need to sort the order of subpkgs!