Build depends for native chroot before "native" cross-compile
Created by: ollieparanoid
Fixes #1061 (closed).
Bug example output
pmbootstrap --mirror-pmOS="" build linux-amazon-thor --strict
>>> linux-amazon-thor: Analyzing dependencies...
ERROR: unsatisfiable constraints:
.makedepends-linux-amazon-thor-0:
masked in: cache
satisfies:
world[.makedepends-linux-amazon-thor]
dtbtool (missing):
required by:
>>> ERROR: linux-amazon-thor: all failed
What happens?
-
linux-amazon-thor
depends ondtbtool
. -
linux-amazon-thor
gets cross-compiled with the "native" method, which means we execute thearmhf
cross-compiler from within the "native" chroot. - when using
--strict
,apk
will install all dependencies of the native chroot - it tries to install
dtbtool
, butpmbootstrap
only built it forarmhf
, not forx86_64
!
Fix description
- When using the "native" cross-compile method, we build the dependencies for the native arch.
- Then
apk
is able to install them in--strict
mode.
How to test
$ sudo rm -v ~/.local/var/pmbootstrap/packages/*/dtbtool*
$ pmbootstrap index
$ pmbootstrap --mirror-pmOS="" build linux-amazon-thor --strict
# this builds dtbtool for x86_64 and armhf before building linux-amazon-thor