macports fetch suggestion

Ryan Schmidt ryandesign at macports.org
Tue Sep 13 01:56:00 PDT 2011


On Sep 13, 2011, at 03:32, Rainer Müller wrote:

> On 2011-09-13 02:12 , Ryan Schmidt wrote:
>> 
>> On Sep 12, 2011, at 11:01, Joshua Root wrote:
>> 
>>> On 2011-9-12 17:54 , Ryan Schmidt wrote:
>>>> If you still find yourself in a situation where MacPorts is
>>>> taking a long time to build a port and you need to leave your
>>>> Internet connection, you can interrupt the build by pressing
>>>> ctrl+c, then fetch any remaining dependencies with "sudo port
>>>> fetch" as above, then resume the installation by re-issuing the
>>>> "sudo port install" command. Note that I would not recommend
>>>> interrupting MacPorts with ctrl+c in any phase other than the
>>>> build phase; doing so might lead to errors when you resume, and
>>>> if so you would have to clean the port and start the build over.
>>> 
>>> I wouldn't trust random build systems to get that right.
>> 
>> In my many years of experience with MacPorts, most ports will resume
>> ok if you interrupt the build phase. A small handful might not.
> 
> It depends in which phase you interrupt the process. The patch or
> destroot phase usually cannot be resumed when they modified files
> already. Executing the same commands again leads to errors.

That's what I intended to say in the paragraph above.


>>> Suspending with ctrl-z is generally a lot safer.
>> 
>> That wouldn't end the port process though, would it? Which wouldn't
>> release the lock. Which is what the whole exercise is about.
> 
> No, it would not release the lock. Locking wasn't even mentioned in this
> part of the thread :-)

The hypothetical situation I posed was: you're building a port that will take awhile, but you need to leave your Internet connection for awhile, and want to fetch the distfiles for other ports. "sudo port fetch a b c" will block waiting for the current build to finish. To avoid that, you must interrupt the current build to release that lock.




More information about the macports-dev mailing list