Summary: | net-misc/dhcpcd-5.6.2: some elog messages should only be shown right after the relevant use flag is enabled. | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | poletti.marco |
Component: | [OLD] Core system | Assignee: | William Hubbs <williamh> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | base-system, gentoo_eshoes |
Priority: | Normal | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Bug Depends on: | |||
Bug Blocks: | 440214 | ||
Attachments: | zeroconf.patch |
Description
poletti.marco
2012-10-31 10:47:53 UTC
(In reply to comment #0) > Such messages should only be displayed when the package is a new install, or > when the relevant USE flag is not enabled in the current installed version. > These situations can be checked in the ebuild as follows: > > if use zeroconf && ! has_version 'net-misc/dhcpcd[zeroconf]'; then This condition will not work in pkg_postinst in this form, because by the time pkg_postinst is running, the has_version portion will always be true. What I would have to do is set a flag in pkg_preinst if the currently installed version has zeroconf turned on, then use that flag in place of the has_version portion of the test you suggest in pkg_postinst. Yes, it makes sense. I'll add this hint to the tracker. Created attachment 328000 [details, diff]
zeroconf.patch
Here is an example of what would need to be done in this case.
What are your thoughts? Is it worth adding the pkg_preinst phase just to
set a flag for this?
I don't think I should be the one to decide this. I don't have much experience with portage, nor with how the portage tree is administered. Also, you are the package maintainer. So my opinion is not well-informed and does not really matter. Please do what you think it's right. If that means not changing the current ebuild to keep it simple and ease future maintenance, feel free to close this bug. As far as I can tell this is taken care of as well as it can be with dhcpcd-5.99.7. If you disagree, feel free to reopen. |