Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 264386 - sys-apps/man should DEPEND/RDEPEND on sys-apps/shadow
Summary: sys-apps/man should DEPEND/RDEPEND on sys-apps/shadow
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All All
: High enhancement (vote)
Assignee: Gentoo's Team for Core System packages
: 284718 361753 (view as bug list)
Depends on:
Reported: 2009-03-31 13:30 UTC by Jeff Mitchell
Modified: 2011-04-04 15:54 UTC (History)
6 users (show)

See Also:
Package list:
Runtime testing required: ---


Note You need to log in before you can comment on or make changes to this bug.
Description Jeff Mitchell 2009-03-31 13:30:51 UTC
sys-apps/man ebuild uses eutils' enewgroup to create a group for man.  eutils in turn uses groupadd, which is provided by sys-apps/shadow.  Unfortunately, man doesn't DEPEND on shadow, so it's possible (when building stages, mainly) to run into a problem where the emerge fails because groupadd isn't installed yet because the package order was not evaluated favorably.

It also needs to RDEPEND on shadow, because if installing from cached binary packages (such as if you are making the packages as you go, so you can quickly build multiple stages), emerge *only* depends on RDEPEND and not DEPEND, so the same problem described above can occur if the package order is evaluated incorrectly.

This should probably be fixed more upstream, i.e. eutils eclass should probably DEPEND/RDEPEND on shadow, to avoid problems with any similar ebuilds.
Comment 1 SpanKY gentoo-dev 2009-03-31 19:28:01 UTC
a proper system will have the user related binaries installed.  release makes sure that shadow is included before other things so that stage building works.
Comment 2 Jeff Mitchell 2009-04-01 11:27:41 UTC
Your logic for closing this bug is faulty.  I've demonstrated that the ebuild has a clear compile-time dependency on shadow, as well as a runtime dependency when using binary packages.  I've said that I have run into this problem in real-world situations (otherwise I wouldn't have filed this bug report).

You are essentially saying that when Gentoo makes an official release, the release team manually goes through dependencies to ensure that your stages are built correctly (since it clearly can fail in an automatic build).  That's great, but it's silly.  By that logic, you might as well remove all DEPEND from all system ebuilds, because the release team will take care of the dependencies when building stages.

This is an actual bug in the ebuild, and it would be nice for you guys to fix it (or fix the eclass) rather than dismissing it offhand.
Comment 3 SpanKY gentoo-dev 2009-04-01 11:41:02 UTC
man itself does not invoke anything from shadow.  the enew{user,group} functions in eutils.eclass do, and how those work is transparent to ebuilds.  any package using those functions are guaranteed the binaries will be available.

your stage building process is flawed because it fails to fulfill that assumption.
Comment 4 Jeff Mitchell 2009-04-01 11:42:27 UTC
If they were available, my emerge wouldn't have failed.
Comment 5 Jeff Mitchell 2009-04-01 11:43:52 UTC
To clarify: they weren't available because portage didn't calculate dependencies correctly when using binary packages, because it uses only RDEPEND.
Comment 6 SpanKY gentoo-dev 2009-04-01 13:22:29 UTC
like i said, adjust your build.  talk to the release team on irc if you dont know how.
Comment 7 Jeff Mitchell 2009-04-01 15:15:59 UTC
What is there to adjust?  It's a normal build of stages, done using normal procedures.  The only difference is that if you use binary packages, emerge screws up because it doesn't evaluate DEPEND, only RDEPEND.  This isn't a build problem with my stages, this is a problem with either emerge, or with RDEPEND in various ebuilds (lots of ebuilds have screwed up DEPEND/RDEPEND values, so this shouldn't be shocking).
Comment 8 SpanKY gentoo-dev 2009-04-01 15:28:39 UTC
funny because i dont see any failures with the Gentoo autobuilds that are constantly running

like i said, if you want support, go ask releng on irc
Comment 9 Jeff Mitchell 2009-04-01 15:32:07 UTC
Do the Gentoo autobuilds use binary packages if available?  If not, you won't see a failure.
Comment 10 Jeff Mitchell 2009-08-23 12:52:27 UTC
I didn't realize this was resolved.
Comment 11 SpanKY gentoo-dev 2009-08-24 06:23:21 UTC
same answer you've been given multiple times
Comment 12 Zac Medico gentoo-dev 2009-08-24 16:26:55 UTC
(In reply to comment #5)
> To clarify: they weren't available because portage didn't calculate
> dependencies correctly when using binary packages, because it uses only

FWIW, you can use --with-bdeps=y to make it pull in DEPEND for binary packages.
Comment 13 Jeff Mitchell 2009-08-25 18:44:42 UTC
Zac, thanks for providing useful information. This should fix my problems.
Comment 14 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2009-11-28 00:19:09 UTC
*** Bug 284718 has been marked as a duplicate of this bug. ***
Comment 15 SpanKY gentoo-dev 2011-04-04 15:54:01 UTC
*** Bug 361753 has been marked as a duplicate of this bug. ***