Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 144781 - portage orphans device files
Summary: portage orphans device files
Status: RESOLVED FIXED
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Core (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Portage team
URL:
Whiteboard:
Keywords: InVCS
Depends on:
Blocks: 147007
  Show dependency tree
 
Reported: 2006-08-22 13:05 UTC by Brian Harring (RETIRED)
Modified: 2006-10-04 03:49 UTC (History)
0 users

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Brian Harring (RETIRED) gentoo-dev 2006-08-22 13:05:10 UTC
not tagging emerge --info (not relevant, features have no affect on treewalks run)

portage ver: 2.1.1_pre5-r3 , and 2.1-r2 (likely more, but that's what I tested).

emerge udev; adds 3 device files, /lib/udev/devices/{console,null,zero} , those files *are* installed by portage, copied from ${IMAGE}.

grep -H '/lib/udev/devices/' /var/db/pkg/sys-fs/udev-*/CONTENTS

enjoy...
Comment 1 Marius Mauch (RETIRED) gentoo-dev 2006-08-22 13:39:44 UTC
What udev version you're talking about? in udev-0.96-r1 I only see device file creation in pkg_preinst (and directly in $ROOT there), nothing in src_install.
Comment 2 Brian Harring (RETIRED) gentoo-dev 2006-08-22 14:12:14 UTC
eenie meenie, one that uses src_install for it; 087-r1 fex.
Comment 3 Marius Mauch (RETIRED) gentoo-dev 2006-08-22 14:29:40 UTC
well, fixing that would be almost trivial on first glance, but comments on that code indicate that it's done on purpose, so this should probably go through -dev:

if stat.S_ISFIFO(mymode):
    # we don't record device nodes in CONTENTS,
    # although we do merge them.
    outfile.write("fif "+myrealdest+"\n")
Comment 4 Brian Harring (RETIRED) gentoo-dev 2006-08-22 14:45:45 UTC
the disabling was done after device support existed then- portage still reads dev entries fine.
Comment 5 Zac Medico gentoo-dev 2006-08-23 00:34:51 UTC
Maybe the purpose is to prevent collision-protect from complaining about device files.  I can't think of any other possible reason atm.
Comment 6 Marius Mauch (RETIRED) gentoo-dev 2006-08-23 01:12:24 UTC
(In reply to comment #5)
> Maybe the purpose is to prevent collision-protect from complaining about device
> files.  I can't think of any other possible reason atm.

Pretty sure that comment is older than collision-protect. Random guess is that it's another "unmerge protection" like with kernel modules, but I really have NFC.
Comment 7 Zac Medico gentoo-dev 2006-08-23 10:19:00 UTC
(In reply to comment #6)
> Pretty sure that comment is older than collision-protect. Random guess is that
> it's another "unmerge protection" like with kernel modules, but I really have
> NFC.

At least as far back as 2.0.51.22, the unmerge code doesn't unmerge device files anyway.  So, if it had anything to do with unmerge, it hasn't been a problem for a while now.  So, the posibility of collision-protect annoyance is the only practical reason that I can think of not to go ahead and list them in CONTENTS.
Comment 8 Jason Stubbs (RETIRED) gentoo-dev 2006-08-23 18:30:40 UTC
It may have slipped in with one of the bulk lightly commented commits of the old days, but I'm pretty sure this has been around since I have - end of 2.0.49. The reason that device files are dealt with incorrectly may be a workaround for some other bug that no longer exists. It is just as likely that when support for device files was added, it wasn't added correctly...
Comment 9 Zac Medico gentoo-dev 2006-10-04 00:18:40 UTC
This is fixed in svn r4588.
Comment 10 Zac Medico gentoo-dev 2006-10-04 03:49:30 UTC
This been released in 2.1.2_pre2-r3.