Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 62321 - unmerging or updating perl leaves many *.ph files on the system
Summary: unmerging or updating perl leaves many *.ph files on the system
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo Perl team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-08-30 18:18 UTC by Sven
Modified: 2005-02-10 04:12 UTC (History)
1 user (show)

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 Sven 2004-08-30 18:18:23 UTC
Hi,

when unmerging perl, the *.ph that were generated aren't unmerged. This happens not only on unmerging, but also on updating perl. For example when upgrading from perl 5.8.2 to 5.8.4, you will have many *.ph files in /usr/lib/perl5/site_perl/5.8.4/i686-linux, but you will also still have those in /usr/lib/perl5/site_perl/5.8.2/i686-linux which aren't needed anymore, still perl 5.8.2 got unmerged.

Reproducible: Always
Steps to Reproduce:
Comment 1 Michael Cummings (RETIRED) gentoo-dev 2004-09-26 05:00:28 UTC
There's nothing we can do here. The .ph files are generated during post-install and are created because some perl apps require them to exist[1]. They are created based on the header files available on your system at the time of install in /usr/include. Unfortunately, they can't really be created until perl is on your real system, so there's no way to get them into CONTENTS which is used for unmerge info.

1. http://www.perldoc.com/perl5.8.4/INSTALL.html#cd--usr-include--h2ph-*.h-sys-*.h
Comment 2 Sven 2004-09-26 10:13:55 UTC
For Python, i sometimes see "cleaning orphaned bytecode" etc.
So for Python, something was written, so that keeps an eye on generated files. You could do the same, for *.ph files, altough that might be more complicated. On the other hand: if there is something like "post-install", can't there be a "post-uninstall"-handler in the perl-ebuilds that deletes the *.ph files if the perl-version was upgraded from 5.8.2 to 5.8.4 for example?

The portage can also be extended by an API, that allows adding files to the database during post-install.

I also don't understand, why the *.ph files are only generated once, because if i upgrade gtk, glibc, linux-headers and such stuff, the header-files get updated, but not the *.ph files? Strange. But that's nothing you should fix. I hope, that in future perl-versions, the *.ph-files get generated and updated on demand.
Comment 3 Michael Cummings (RETIRED) gentoo-dev 2005-02-10 02:58:56 UTC
New version of perl ebuild about to hit the trees that will clean out the old .ph files (just running through the last batch of emerging each perl version now). Also, perl-cleaner, the replacement for libperl_rebuilder, can clean these out. Closing this as the commit is less than an hour away.
Comment 4 Sven 2005-02-10 04:12:49 UTC
Already noticed the new perl-cleaner script. Works great. Thank you!