if I tell it to compile a package which has deps on other packages that aren't compiled yet, it'll install all the deps for all packages combined before starting to compile the first in the list, even with --strict
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Child items 0
Show closed items
No child items are currently assigned. Use child items to break down this issue into smaller parts.
Linked items 0
Link issues together to show that they're related.
Learn more.
What originally happened (installing too many deps) does not seem to happen anymore. The chroots get zapped properly before building a new package.
However, sometimes it can not find a dependency if it has not been compiled yet. I just had a case of this again.
I tried building plasma-settings which has a dependency on kirigami2, neither of them had been compiled (for this architecture) before. Instead of first compiling kirigami2, it just errored out.
Thanks for the detailed information, that makes a lot of sense. We actually only care about the makedepends in the usual, non-strict mode, as a performance hack. That way, you can build device- packages without building the actual linux packages. But for the strict-mode, we should really build the real depends, too.
I've quickly written down a patch, which should fix this in theory. Could you try if that works for you?
--- a/pmb/build/package.py+++ b/pmb/build/package.py@@ -58,12 +58,11 @@ def package(args, pkgname, carch, force=False, buildinfo=False, strict=False): # Initialize build environment, install/build makedepends pmb.build.init(args, suffix)- if len(apkbuild["makedepends"]):- if strict:- for makedepend in apkbuild["makedepends"]:- package(args, makedepend, carch_buildenv, strict=True)- else:- pmb.chroot.apk.install(args, apkbuild["makedepends"], suffix)+ if strict:+ for depend in apkbuild["makedepends"] + apkbuild["depends"]:+ package(args, depend, carch_buildenv, strict=True)+ else if len(apkbuild["makedepends"]):+ pmb.chroot.apk.install(args, apkbuild["makedepends"], suffix) if cross: pmb.chroot.apk.install(args, ["gcc-" + carch_buildenv, "g++-" + carch_buildenv,
Also I've noted that this behavior wasn't mentioned in build internals so I'll document it there now.
In my opinion, this is a blocker for merging your plasma work (#440). So let's look at it again.
Summary
abuild considers alldepends as build-time dependencies. pmbootstrap only considers makedepends as build-time dependencies. This is a performance hack, and allows fast building of device-* packages without building the kernel it depends on.
Plan to resolve this
I think to fix this incompatibility with Alpine's packaging, we should adopt to how Alpine does it by default. To preserve the performance hack (which is quite useful for mass-editing and building device-* packages), I would put it behind a flag:
What I'm saying is, that it should also work that way even if --strict is not defined. It would still make sense to have --strict to start with a clean chroot and only install the depends, which are required (like it works now).