Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 178594

Summary: mail-filter/amavisd-new - first pkg_preinst should be pkg_setup
Product: Gentoo Linux Reporter: sakkath
Component: New packagesAssignee: Net-Mail Packages <net-mail+disabled>
Status: RESOLVED FIXED    
Severity: normal CC: antivirus, jmbsvicetto
Priority: High    
Version: unspecified   
Hardware: AMD64   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---

Description sakkath 2007-05-15 02:38:31 UTC
< jmbsvicetto> That pkg_preinst should be pkg_setup
< Sakkath> bug report?
< jmbsvicetto> Yes, I'll do that
< jmbsvicetto> You can say that currently *ALL* amavisd-new ebuilds have that error!
< Sakkath> is that true?
< jmbsvicetto> grep -B 4 enewuser /usr/portage/mail-filter/amavisd-new/amavisd-new-2* shows that ;)

------------------------------------------------------------------

I had amavisd-new installed (2.5.0) and I unmerged and did userdel amavis and then the remerge did not readd the user.

Reproducible: Always

Steps to Reproduce:
1. emerge amavisd-new
2. userdel amavis
3. emerge amavisd-new

Actual Results:  
The user/group amavis does not exist and at the end of the merge you'll see:
chown: `root:amavis': invalid group
chown: `amavis:amavis': invalid user

Expected Results:  
Readded the user.

Ask jmbsvicetto on IRC (Freenode/#Gentoo-netmail), he was the one who told me this is wrong.
Comment 1 Andrej Kacian (RETIRED) gentoo-dev 2007-05-23 22:52:33 UTC
Ah, sorry about that.

I have moved both enew* calls to real pkg_preinst() - it's better when it's added after the package is ready to be installed - src_compile() or src_install() phase may fail and we don't want the user added in that case.

Feel free to reopen or ping me on IRC if you disagree.
Comment 2 sakkath 2007-05-24 00:45:06 UTC
Thanks a lot =).