Page MenuHomeFreeBSD

packages: Set dependency origin in generate-ucl.lua
ClosedPublic

Authored by ivy on Fri, Oct 3, 6:09 PM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Oct 10, 10:25 AM
Unknown Object (File)
Fri, Oct 10, 10:25 AM
Unknown Object (File)
Thu, Oct 9, 10:42 PM
Unknown Object (File)
Thu, Oct 9, 10:42 PM
Unknown Object (File)
Thu, Oct 9, 9:49 PM
Unknown Object (File)
Thu, Oct 9, 7:13 PM
Unknown Object (File)
Thu, Oct 9, 1:31 PM
Unknown Object (File)
Tue, Oct 7, 1:18 PM

Details

Summary

Commit 822fd5606748 changed the origin of packages from "base"
to "base/<package name>", but the old origin was still used for
dependencies.

Aside from being wrong, this confuses pkg <= 2.3.1 and causes
"pkg info -d" to show the dependencies as "<pkgname>-(null)"
instead of the correct version string.

Remove the explicit origin from dependencies in the UCL files,
and instead populate this during the build in generate-ucl.lua.
In the (very unlikely) case that an explicit origin is still
needed, don't overwrite one if it's already present.

Fixes: 822fd5606748 ("pkgbase: set origin for each packages as base/FreeBSD-*")
Reported by: bapt
MFC after: 3 seconds

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

ivy requested review of this revision.Fri, Oct 3, 6:10 PM
cperciva added a subscriber: cperciva.

I'm not 100% confident that I understand the code well enough to review it, but the explanation makes sense and the patch is at least plausible. Go for it.

This revision is now accepted and ready to land.Sun, Oct 5, 4:39 PM

also fix the set packages

This revision now requires review to proceed.Tue, Oct 7, 4:17 AM
This revision is now accepted and ready to land.Tue, Oct 7, 8:57 AM