CFT: New version of portmaster in svn

Doug Barton dougb at FreeBSD.org
Sat Jul 24 00:13:08 UTC 2010


On Fri, 23 Jul 2010, jhell wrote:

> On 07/23/2010 15:00, Doug Barton wrote:
>>
>> Now what I _could_ do is use the same technique I use in
>> --clean-distfiles (create a text file with the distfile information) but
>> instead of limiting it to installed ports, do all of them. I have never
>> even tested that to see how long it would take, but I suppose I could
>> take a look.

Turns out this wasn't quite as painful as I thought it would be, so I've 
added the feature to svn version r210440. On my system, without a full 
ports tree, it takes between 3.5 and 4.5 minutes to build the list.

> Hi Doug Barton, Ports@,
>
> Here is a suggestion that I have just played around with involving
> locate(1) with environment LOCATE_PATH set in portmaster & ports-side
> locate.updatedb(8) with LOCATE_CONFIG before the port snapshots are made.

This is certainly an interesting idea, however it has a lot of potential 
problems. Best case scenario on a default system with ports tree updated 
just before locate.db is created, on average the information would be 
3.5 days out of date.

There is also another problem, not all of the ports' distinfo files are 
named "distinfo." Most of them are, but not all.

> Server side: ( at port snapshot creation )
> 	LOCATE_CONFIG=/usr/ports/locate.rc /usr/libexec/locate.updatedb
> 		locate.rc:
> 			FCODES="/usr/ports/locate.database"
> 			SEARCHPATHS="/usr/ports"
>
> real 149.79

It's not 100% clear to me what you're timing here, but it took 2.5 
minutes to do it.

> Use the output from that to judge if the file in /usr/ports/distfiles
> needs to exist or of the file does not meet the SIZE requirements & you
> can kill two birds with one stone.

Currently --clean-distfiles doesn't attempt to validate that the file 
matches the specs in the distinfo file, and I don't see a compelling 
reason to add that feature. It would be very difficult (nearly 
impossible) to accidentally save an invalid file, and totally impossible 
to use one to build a port.

> Just for creating the list of distfiles from the SIZE contents:
> $ du -sh DISTINDEX.8.1.gz
> 512B    DISTINDEX.8.1.gz
>
> time -alhp ./createindex.sh
> real 490.99

Sorry I'm so dense, but I'm still not following exactly what part of the 
process you're referring to here, but this time it took over 8 minutes. 
Given that the method I'm using to generate a 100% up to date version of 
the list that's guaranteed to get all the distfiles takes less time, I 
do not think I will be adding the feature you are suggesting, but I do 
appreciate the suggestion. :)


Doug

-- 

 	Improve the effectiveness of your Internet presence with
 	a domain name makeover!    http://SupersetSolutions.com/

 	Computers are useless. They can only give you answers.
 			-- Pablo Picasso



More information about the freebsd-ports mailing list