XBPS_STATEDIR is created in XBPS_BUILDDIR/.xbps-${sourcepkg}-${version}
and contains logs and state files for all phases, as well as wrappers.
We can now inspect the output from all hooks.
common/build-profiles contains the compilation flags used in native
builds, and are defined per architecture:
- x86_64 (glibc)
- x86_64-musl (musl)
If XBPS_CFLAGS or XBPS_CXXFLAGS are set in `etc/conf`, the settings
from the build profile will be overrided.
- This should work for almost 90% current packages, as reported by OpenBSD/ports.
- Packages that use install -o <user> -g <group> will get fixed progressively.
- xbps-create(8) by default sets pkg files as 0:0, if any pkg needs special
permissions those can be set via INSTALL scripts (for now).
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!
10 Non development packages are processed first lexically.
20 Development packages are processed after 10.
This resolves the issue of 32bit pkg creation with development pkgs
that depend on other non-development subpkgs, and result in wrong
dependencies being propagated to the 32bit development pkgs.
- broken var simply exits (without error) and skips building a pkg.
- nocross var now simply exits without an error, to make buildbot continue building pkgs.
The syntax "pkg?vpkg" can be used in hostmakedepends, makedepends and depends;
but the "virtual" keyword can be declared specifically for runtime dependencies
(depends).
Permanent global pkg build options can be defined via 'XBPS_PKG_OPTIONS' in etc/conf.
Permament per-pkg build options can be defined via 'XBPS_PKG_OPTIONS_<pkgname>' in etc/conf.
Close GH #452.
The new xbps-src configuration file is `etc/conf` where you can
add your local overrides from defaults set via `etc/defaults.conf`.
To use this xbps-src, run these steps:
$ make
$ sudo make setup (to make chroot helper setgid)
$ ./xbps-src ...