Is it safe to compile multiple ports at the same time ?

Vasil Dimov vd at FreeBSD.org
Wed May 17 06:21:50 UTC 2006


On Wed, May 17, 2006 at 04:13:02PM +1000, Edwin Groothuis wrote:
> On Wed, May 17, 2006 at 09:00:26AM +0300, Vasil Dimov wrote:
> > Not really, locking will just prevent breakages. Let me illustrate my
> > thought with an example:
> > 
> > port A depends on X
> > port B depends on X
> > 
> > You start building A which results in building X via exclusive lock on X.
> > During the build of X you decide to build B which results in building X
> > (X is not yet installed) but you block trying to acquire the exclusive
> > lock on X so you wait _idling_ until building of X is done. Furthermore
> > what do you suggest to do when the lock is released?
> 
> You have to obtain a lock on the X's Makefile before you are doing
> to check if you have this port installed.
> 
> For example, a dependcy on pkg-config in the directory devel/pkgconfig:
> 
> - obtain lock on devel/pkgconfig/Makefile
What do you do if that is already locked?

> - check if pkg-config exists, and if not, build and install it.
> - release lock on devel/pkgconfig/Makefile
> 
> 
> > Ofcourse if B depends also on Y it can fallback to building Y if it
> > cannot gain exclusive lock on X.
> 
> Building one port is a serial process, building multiple ports can
> be a parallel process.
> 
Agreed.

-- 
Vasil Dimov
gro.DSBeerF at dv

Testing can show the presence of bugs, but not their absence.
                -- Edsger W. Dijkstra
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 155 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-ports/attachments/20060517/cb36b40a/attachment.pgp


More information about the freebsd-ports mailing list