Gentoo Archives: gentoo-osx

From: Grobian <grobian@g.o>
To: gentoo-osx@l.g.o
Subject: [gentoo-osx] using curl to fetch files (the default in the OSX installer)
Date: Sat, 06 Aug 2005 08:32:44
Hi all,

While working on an ebuild I noted that that while downloading distfiles 
from the mirrors I ended up with files filled with 404 HTML pages.  It 
became clear soon, that curl was just downloading these pages and 
returned 0 to indicate success.  After a discussion with 2r2d in #-osx 
we came to the conclusion that curl needs the -f (-fail) flag in order 
to return something like this on a 404:

curl: (22) The requested URL returned error: 404

I tested this in my FETCHCOMMAND (I put the -f just in front of the -#) 
and verified that with this flag curl behaves as portage expects it and 
goes on to the next mirror if the file was not found.

I think this change should be into our installer, as it is a simple fix 
which prevents some hair-pulling :)

Fabian Groffen
eBuild && Porting
Gentoo for Mac OS X 

gentoo-osx@g.o mailing list