portindex ignores (filters out) unchanged port

René J.V. Bertin rjvbertin at gmail.com
Tue Dec 29 06:06:40 PST 2015


On Tuesday December 29 2015 12:05:30 Rainer Müller wrote:
> On 2015-12-29 00:10, René J.V. Bertin wrote:
> > The Portfiles *are* scanned if and when they have to be (re)indexed;
                                ^^     ^^^^

> No, the Tcl interpreter is only run on the Portfile if the mtime of the
                                                      ^^
> Portfile is newer than the mtime of the existing PortIndex. Just look at


Just how is what you are saying different from what I was saying? You just explain the current condition under which Portfiles are parsed. I presume it also happens when a portdir gets renamed without changing the Portfile's mtime, or when an older portdir+Portfile is added to the tree.

My proposition is to parse a Portfile only when
1 its mtime is newer (or just different)
2 it lives in a portdir not yet known
3 its hash is different from the one stored in one or both of the PortIndex files (or none is stored, but that should already be caught by 2)
 
1) is mostly a simple way to force a reindexing, 2) should catch most new Ports and 3) catches anything else. Any Portfile that doesn't trip one of the conditions shouldn't require indexing AFAICS, regardless of whether the port and portdir names match or not.

Am I missing something?

R.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-dev/attachments/20151229/3d46f79a/attachment-0001.html>


More information about the macports-dev mailing list