Solved How to deal with circular dependencies exactly?

I am encountering circular dependencies on a regular basis. Maybe I am too keen on turning knobs on? Anyways, usually they crash the build machine because of too much memory/swap consumed, unless I notice it and break the compilation earlier. Which is quite annoying to say the least, because then I need to track it down and start recompilation from scratch. It would be great if someone enlightened me how this should be dealt with because in the current state compilation from ports simply doesn't work for me.

I presume that ports are checked for circular dependencies with automatic tools when all the knobs are set to their default states. But how to detect circular dependencies on a particular build machine when knobs are set to non-default states? Is running the build process to see if it breaks the only option?

I noticed that make index in /usr/ports/ can detect a circular dependency somehow but the message it prints when it's found is pretty useless, .e.g:

Code:
make_index: Circular dependency loop found: nautilus-3.16.3 depends upon itself.

How to check what ports the circular dependency consists of so that I can break it by looking for knobs/options to turn off?
 
I send an email to the mailing list, if I encounter even the option that leads to a circular dependency. It seems to be fixed soon after. It represents useless redundancy, and I don't think FreeBSD is supposed to have them.

Swap is another issue of its own, sometimes you'll have to flush the swap after a few ports are built, or add more swap space.
 
OK, but how do you find out the path of the circular dependency? I can't just post that nautilus depends on itself?
 
One way to go through dependencies quickly is to go into the port's directory, and type:
make rmconfig-recursive
make config-recursive
config-recursive may have to be typed several times, until all dependency options are taken care of.

This will make troubleshooting easier. In most cases that will be enough. It might takes notes to pinpoint or provide the information. To go further, you may use www.freshports.com (which may not help with user-set options), or to less at specific port's Makefile 's.
 
Last edited by a moderator:
I installed poudriere. I can switch knobs to my liking and test the build without breaking my system, which is great! I can then install only committed packages. And if something goes wrong I have the log which I can investigate further and report. And on top of that, it feels really great to watch poudriere when it cleanly reports the status of the compilation process and then again when pkg happilly installs my customized packages :)
 
Back
Top