diff options
author | Michael Cummings <mcummings@gentoo.org> | 2005-05-30 13:41:04 +0000 |
---|---|---|
committer | Michael Cummings <mcummings@gentoo.org> | 2005-05-30 13:41:04 +0000 |
commit | cf539edbc536d7c15570bfdc0ebea8e9ef07b1b2 (patch) | |
tree | 649ebcbd8acc59f61f63aa6bde42eee79afc440b /dev-lang/perl/files | |
parent | make use of our initscript again, fixes #94350. the initscript now supports c... (diff) | |
download | gentoo-2-cf539edbc536d7c15570bfdc0ebea8e9ef07b1b2.tar.gz gentoo-2-cf539edbc536d7c15570bfdc0ebea8e9ef07b1b2.tar.bz2 gentoo-2-cf539edbc536d7c15570bfdc0ebea8e9ef07b1b2.zip |
Updated perl-cleaner to remove the emptied dirs after a .ph purge
(Portage version: 2.0.51.22-r1)
Diffstat (limited to 'dev-lang/perl/files')
-rwxr-xr-x | dev-lang/perl/files/perl-cleaner | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/dev-lang/perl/files/perl-cleaner b/dev-lang/perl/files/perl-cleaner index a2a9becff7e9..5831c5e02424 100755 --- a/dev-lang/perl/files/perl-cleaner +++ b/dev-lang/perl/files/perl-cleaner @@ -68,13 +68,19 @@ function ph_clean() { done fi done + for DIR in $INC; do + for empty in $(find $DIR -type d); do + # Silently remove those dirs that we just emptied + rmdir $empty >/dev/null 2>&1 + done + done } # Generate ph files; this is useful if we've upgraded packages with headers so that perl knows the new info function ph_update() { echo "$(date) : Updating ph files" | tee -a $LOG - cd /usr/include; h2ph * sys/* arpa/* netinet/* bits/* security/* asm/* gnu/* linux/*>>$LOG - cd /usr/include/linux; h2ph * >>$LOG + cd /usr/include; h2ph * sys/* arpa/* netinet/* bits/* security/* asm/* gnu/* linux/* | tee -a $LOG + cd /usr/include/linux; h2ph * | tee -a $LOG } # Build a list of modules installed under older perls - only valid if the module was an ebuild :) |