Skip to content

Conversation

@arthurzam
Copy link
Member

This commit copies from @mgorny 's blog posts about common pitfalls in writing dependencies, and adds them to the devmanual.

I've added his sign off (based on https://bugs.gentoo.org/587526#c2) but it might have been wrongly done - but I don't really know the correct way to attribute here (I do want to mention him as the super main source).

Closes: https://bugs.gentoo.org/587526

Comment on lines +1117 to +1121
In <c>PDEPEND</c>, weak blockers act effectively like those in
<c>RDEPEND</c>, while strong blockers behave more like weak ones because
satisfaction may be delayed post-install.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think that's true, is it?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mgorny your text states this:

This leaves PDEPEND which is a bit unclear. Again, technically both blocker types are valid. However, weak blockers in PDEPEND would be pretty much equivalent to those in RDEPEND, so there is no reason to use that class. Strong blockers in PDEPEND would logically be equivalent to weak blockers — since the satisfaction of this dependency class can be delayed post install.

Should I just drop this bullet since it is unclear?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should drop it. I'm not convinced it's guaranteed.

@arthurzam arthurzam force-pushed the common-deps-fails branch 5 times, most recently from 78b2874 to f29c37c Compare December 20, 2025 08:11
@arthurzam arthurzam requested review from laumann and thesamesam and removed request for laumann December 20, 2025 08:22
@arthurzam arthurzam requested a review from ulm December 20, 2025 12:12
Copy link
Member

@ulm ulm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Otherwise LGTM.

This commit copies from mgorny's blog posts about common pitfalls in
writing dependencies, and adds them to the devmanual.

Signed-off-by: Michał Górny <mgorny@gentoo.org>
Closes: https://bugs.gentoo.org/587526
Signed-off-by: Arthur Zamarin <arthurzam@gentoo.org>
@arthurzam
Copy link
Member Author

@ulm please merge it if you are fine with this PR

Copy link
Member

@thesamesam thesamesam left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm with some comments


<codesample lang="ebuild" caption="Example of correct use of := outside any-of">
IUSE="a b"
REQUIRED_USE="^^ (a b)"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
REQUIRED_USE="^^ (a b)"
REQUIRED_USE="^^ ( a b )"

Comment on lines +1117 to +1121
In <c>PDEPEND</c>, weak blockers act effectively like those in
<c>RDEPEND</c>, while strong blockers behave more like weak ones because
satisfaction may be delayed post-install.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should drop it. I'm not convinced it's guaranteed.

@ulm
Copy link
Member

ulm commented Dec 30, 2025

@ulm please merge it if you are fine with this PR

@thesamesam still had some comments. (@arthurzam: I can apply these two changes when merging if that's o.k.)

@arthurzam
Copy link
Member Author

@ulm please merge it if you are fine with this PR

@thesamesam still had some comments. (@arthurzam: I can apply these two changes when merging if that's o.k.)

please do, I'm currently resting after returning from military service...

@ulm
Copy link
Member

ulm commented Dec 30, 2025

Merged, with the whitespace change applied and the PDEPEND bullet point dropped.

@ulm ulm closed this Dec 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants