Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 62669 - libperl_rebuilder should really be a bit more robust
Summary: libperl_rebuilder should really be a bit more robust
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-09-02 16:38 UTC by CJ Kucera
Modified: 2005-01-26 09:24 UTC (History)
1 user (show)

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


Attachments
Patch to only rebuild modules once. (libperl_rebuilder.patch,3.89 KB, patch)
2004-09-09 20:37 UTC, Mathias Gug
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description CJ Kucera 2004-09-02 16:38:19 UTC
I'm using libperl_rebuilder currently on my system, and I've noticed that it's currently on the third pass of rebuilding every single dev-perl package that I have installed.  This is because one package in particular doesn't actually exist under dev-perl anymore (it's been moved to a different place apparently, but I've still got it installed), and because libperl_rebuilder notices that *something* failed, it's just going ahead and rebuilding *everything,* even the packages which worked fine.

I noticed something similar when moving onto pass 2; the only other package that had failed on pass 1 was DBD-mysql, because DBI was coming up next in line.  There was no reason for any of the other dev-perl packages to be re-tried during pass 2.  The list of packages should really be trimmed down as successful compiles happen.

Reproducible: Always
Steps to Reproduce:
Comment 1 CJ Kucera 2004-09-02 18:54:29 UTC
Actually, looking a bit more closely at the source code, I notice that there wasn't so much a check to see if any packages failed so much as just a loop which will try everything three times regardless.  It'd be really great to have that changed.

In addition, while running it, it's encountered a few problems with having packages masked and packages no longer in portage, and in every case it's simply dropped me back to the shell saying "fix this."  If I were to just fix that one problem and then run libperl_rebuilder again (as would seem logical), the utility will currently just start way over at the beginning again, compiling all the installed dev-perl modules THREE TIMES (again) before possibly coming across another error.  If I hadn't copied the util over and started commenting out large chunks of it, I'd be pulling my hair out right about now.

One of the things I've always loved about Gentoo is that the utilities are generally absolutely fantastic.  This one would be great too if it could just be made a little more robust.

I'll see if I can come up with some patches which would help the situation a bit, though it'll probably be next week sometime before I'd have a chance to do so.
Comment 2 Thilo Six 2004-09-06 13:49:16 UTC
Also have a look at:

#48024 libperl_rebuilder should do --oneshot emerges
http://bugs.gentoo.org/show_bug.cgi?id=48024
Comment 3 Mathias Gug 2004-09-09 20:37:28 UTC
Created attachment 39284 [details, diff]
Patch to only rebuild modules once.

This patch makes libperl_rebuild only build once all installed perl modules.

It also includes fixes from bug 62301 and bug 48024.

Please test the case when perl modules fails to compile.
Comment 4 Michael Cummings (RETIRED) gentoo-dev 2004-10-16 07:22:15 UTC
http://dev.gentoo.org/~mcummings/perl-cleaner

Intended to do the job that libperl_rebuilder does (but cleaner, with oneshots, and better determination of what specifically needs to be reinstalled) as well as some other perl tree maintenance. Feedback most welcome before it hits the tree :)
Comment 5 Joakim 2004-11-20 01:35:17 UTC
Nice script, seam to do a good job.
Found a typo though:
Press any key to see the list of ebuilds we'll be avaluating

I guess it should be 'evaluating' at the end, also 'any key' doesn't seam to work, I had to hit Enter to make it move on, other keys just shows up on screen.

Two questions as well.

1. it listed the items below for me and I have some distant memory of fiddling with and not get java to work, I think it must have been during 1.4 as my system started out as. The package below are defenately not used anymore, but were did 'perl-cleaner' get info about it? I most likely would like to remove those referenses and clean out the 'leftovers' in /opt

Sat Nov 20 09:14:16 UTC 2004 : Building list of modules for reinstall
Locating modules for reinstall
Sat Nov 20 09:14:21 UTC 2004 : Locating ebuilds linked against libperl
find: /opt/blackdown-jdk-1.4.1_beta/jre/lib/i386/native_threads/: No such file or directory
find: /opt/bin: No such file or directory
find: /opt/blackdown-jdk-1.4.1_beta/bin: No such file or directory
find: /opt/blackdown-jdk-1.4.1_beta/jre/bin: No such file or directory

I ran 'perl-cleaner' twice, first time, apart from 2 other packanges, it found a referense to a none existing media-libs/pdflib-4.0.3-r1 packages and asked about installing a newer one, which I Y and 5.0.2 was installed. The second time it again found media-libs/pdflib-4.0.3-r1 and wanted to install, but not available so after Y again went for 5.0.2? I think only php using this, and I guess it can be that php need to be recompiled to pick up the new pdflib and let go of it old one... otherwise, I guess you have something there.
Comment 6 Mathias Gug 2004-12-08 11:05:41 UTC
I tested perl-cleaner from comment #4.

I've the following problem if there is any thing to rebuild :

root # ./perl-cleaner libperl
Wed Dec  8 14:02:18 EST 2004 : Locating ebuilds linked against libperl
find: /opt/bin: No such file or directory
Wed Dec  8 14:02:24 EST 2004 : Rebuilding modules: Building list of ebuilds
Reinstalling ebuilds
Calculating dependencies
emerge: there are no ebuilds to satisfy "=[".
 
 
For a complete log, please read /tmp/perl-cleaner.log
 
root # cat /tmp/perl-cleaner.log
Wed Dec  8 14:02:18 EST 2004 : Locating ebuilds linked against libperl
Wed Dec  8 14:02:25 EST 2004 : Rebuilding modules: Building list of ebuilds
Wed Dec  8 14:02:25 EST 2004 : Ebuilds to reinstall:
=[


If there is anything that needs to be recompiled, perl-cleaner should say so, rather than failing.
Comment 7 Mathias Gug 2004-12-08 11:08:53 UTC
Hum... Comment #6 refers to the situation where there is nothing to be rebuild (ebuilds.ordered is empty)
Comment 8 Michael Cummings (RETIRED) gentoo-dev 2004-12-25 06:35:33 UTC
I'm in the process of updating perl_cleaner to reflect when there's nothing to do (who woulda thought of that ;) ) and for a more spartan h2ph run (like we've recently implimented in the main perl ebuilds). Will update sample copy prior to actually posting to the tree.
Comment 9 Michael Cummings (RETIRED) gentoo-dev 2005-01-26 09:24:11 UTC
simple size test of the ebuilds.ordered file fixed this. perl-cleaner is in the tree and live. Closing this out,

mike