Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 28 Jan 2012 14:37:34 +0000
From:      RW <rwmaillists@googlemail.com>
To:        ports@freebsd.org
Subject:   Re: A new and better way to do "make readmes"?
Message-ID:  <20120128143734.6166f5fc@gumby.homeunix.com>
In-Reply-To: <20120127200325.66f36090@cox.net>
References:  <20111203173149.224a64e6@cox.net> <20111214004838.GK1593@dormouse.experts-exchange.com> <20120112212905.GA78819@dormouse.experts-exchange.com> <20120127200325.66f36090@cox.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, 27 Jan 2012 20:03:25 -0600
Conrad J. Sabatier wrote:

> I've been thinking for a long time that we need a better way to do
> "make readmes", one that would be properly integrated into our
> ports Mk infrastructure, to take advantage of make's ability to
> recognize which files are up-to-date and which really do need
> rebuilding.

This wont help and I think there's a better way that will make it up to
700 times faster.

When a make readmes is done at the top-level, the top-level and
category READMEs are created by make targets and the per port READMEs
are created by a perl script in one go from the INDEX-<n> file. 

I once timed this and the 64 category  READMEs took 2 hours, but the
~20,000 port READMEs only took about 9 seconds.  Selective updating
isn't going to help because 99.9% of the time is spent in the
categories and it only takes a single port update to make a category
file obsolete.

I think the way to speed this up is to have the script generate the
category files too. There's no point in bringing in the top-level
README since that's already fast.

I've been toying with the idea of doing this, but have never got around
to it. If anyone wants to have a go I think it would be sensible to
write it in awk, since perl is no longer in the base system and the
existing perl script isn't really complex enough to be worth hanging-on
to. 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20120128143734.6166f5fc>