handling circular dependencies

wookietreiber kizkizzbangbang at googlemail.com
Sun Jan 16 10:02:35 CET 2011


Thanks, I used 'module_installed' in my recent submissions, too, which I guess is the common workaround for circular dependencies right now.

But exactly this is what I think can be avoided by implementing circular dependency handling functionality -- so the module writer does not have to deal with this kind of stuff. This takes a lot of responsibility, time and maintenance from the module writer/writing to the lunar tools. And, of course, it makes the module script files smaller and more easily readable/understandable.

> The problem is that there doesn't appear to be a definitive guide on
> how to handle this sort of problem anywhere.

That's why I encourage you to think about this problem, so we can make our own guide on this :)

Best regards
Christian Krause aka wookietreiber


On Sun, Jan 16, 2011 at 09:33:45AM +0100, Duncan Gibson wrote:
> > revising the configuration of 'cairo' and much around it (take a look at
> > the module submission queue) I discovered some circular dependencies
> > ('libspectre', 'poppler' and 'librsvg' should actually be optional
> > dependencies for 'cairo') and how troublesome and annoying they can be ...
> > for now I handled them with POST_INSTALL and POST_REMOVE, which, of
> > course, isn't the most elegant way to do this ...
> 
> so far I have only noticed circular depends problems in "lvu stree".
> It may just need a change in the logic, but maybe it's not so easy to
> achieve in bash.
> 
> The alternative is to leave out one of the depends, or better still,
> to comment it out with a reason why, and then add an explicit 'lin'.
> There are lots of examples within moonbase that use 'module_installed'
> but maybe some of them could/should be rewritten.
> 
> The problem is that there doesn't appear to be a definitive guide on
> how to handle this sort of problem anywhere.
> 
> I append two random examples of 'module_installed' use.
> 
> Cheers
> Duncan / engelsman
> 
> video/xvidcore/POST_INSTALL:
>   if module_installed MPlayer;   then lin -c MPlayer;   fi
> 
> x11/xplanet/BUILD:
>   if module_installed xscreensaver; then
>     OPTS="$OPTS --with-xscreensaver"
>   fi                                       &&
> 
> 
> _______________________________________________
> Lunar-dev mailing list
> Lunar-dev at lunar-linux.org
> http://foo-projects.org/mailman/listinfo/lunar-dev



More information about the Lunar-dev mailing list