Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 19462 - ldconfig runs when its not needed
Summary: ldconfig runs when its not needed
Status: RESOLVED WONTFIX
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Unclassified (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Nicholas Jones (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-04-17 01:59 UTC by Dylan Carlson (RETIRED)
Modified: 2011-10-30 22:20 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 Dylan Carlson (RETIRED) gentoo-dev 2003-04-17 01:59:55 UTC
Hopefully this irc transcript will tell the whole story.  :)  TIA

(01:46) @<absinthe> seemant: one thing i've noticed and i'm sure this has been commented on already, but portage runs ldconfig more than it needs to be run.
(01:46) @<seemant> absinthe: make an analysis and/or patch and talk with nick about it
(01:46) @<woodchip> absinthe: i dont think that's correct... i know nick worked on that quit a bit a while ago...
(01:46) @<absinthe> seemant: well my general feeling is that portage shouldn't run ldconfig unless it knows it installed libs.
(01:47) @<absinthe> it seems to run ldconfig for everything.
(01:47) @<seemant> absinthe: that's added complexity too, though
(01:47) @<absinthe> true, but saves a lot of time for packages that don't install libs.
(01:47) +<Magnade> seemant: not by much if done right
(01:47) @<seemant> oh?
(01:48) +<Magnade> well if you were to have portage just load up the lib dirs that ldconfig scans into an array
(01:48) +<Magnade> just before merging the stuff
(01:48) +<Magnade> it can just check the path while its moving files
(01:49) +<Magnade> then just a if libs ldconfig
(01:49) @<seemant> conceivably, it could just test for presence of those directories in ${D}, then
(01:49) @<seemant> instead of scanning path while merging
(01:50) +<Magnade> seemant: true but if portage is making a package there isnt a need to run those checks
(01:53) @<absinthe> seemant: to further my point from earlier, i just merged the latest -ck kernel, and it runs ldconfig TWICE.  once after the merge, and once on autoclean... ugh.
(01:53) @<absinthe> once is one time too many for merging kernel source...  :)
(01:54) @<seemant> absinthe: is that wrong?
(01:54) @<absinthe> it's unnecessary...
(01:54) @<absinthe> just adds to the amt of time needed to merge stuff that otherwise doesn't install libs.
(01:54) +<Magnade> on a slower system those runs can really add up
(01:54) +<Magnade> more so if its low mem :\
(01:54) @<absinthe> that's more or less my point, yes
(01:55) @<seemant> absinthe: open a bug to nick
Comment 1 Nicholas Jones (RETIRED) gentoo-dev 2003-04-21 19:43:40 UTC
The reason it runs ldconfig so many times is mostly for safety.

The problem with doing as is suggested here is that env_update would
have to be informed of all information used for merging and unmerging
packages. env_update is completely seperate from the merge process
and updates the files used when calculating ldconfig's path info.

It's a complexity and safety issue... This might get cleaned up more
in the distant future, but for the time being, it won't change.