Python 2.6 update with portmaster

Mel Flynn mel.flynn+fbsd.ports at mailing.thruhere.net
Wed Jun 10 23:47:31 UTC 2009


On Wednesday 10 June 2009 12:52:36 Wesley Shields wrote:
> On Wed, Jun 10, 2009 at 12:44:42PM -0800, Mel Flynn wrote:
> > On Wednesday 10 June 2009 05:26:47 Wesley Shields wrote:
> > > It will be quite slow compared to using pkg_which (the normal method)
> > > so be patient.
> >
> > Does pkg_which use the pkgdb? If so, maybe we could have pkg_info grow a
> > cache for future encounters, or we can create one:
>
> My guess is that pkg_which is using pkgdb, which is why it is
> significantly faster.
>
> > % grep -v '^@' /var/db/pkg/*/+CONTENTS >/tmp/pkg_info.cache
> > % FOUND=`sed -ne 's,^/var/db/pkg/\(.*\)/+CONTENTS:lib/python2.6/site-
> > packages/xcbgen/error.py$,\1,p' /tmp/pkg_info.cache`; echo $FOUND
> > xcb-proto-1.4
> >
> > So:
> > 's,^${PKG_DBDIR}/\(.*\)/+CONTENTS:$$f$$,\1,p'
>
> I think there is a SoC project in the works to make our pkg utilities
> much better. I don't know any of the details but I can only hope that
> speed is one of the things being improved.

True, however the above can be done now, though it's a bit tricky to squeeze 
into the find command, one could put this as shell script in files/pkg_which.
And patch Makefile as attached.

I haven't got a system to run this on, since I switched to 2.6 everywhere a 
long time ago, but the find command on the shell produced the desired output.

> > > [1]: http://people.freebsd.org/~wxs/python26-portmaster.diff
> >
> > What's this for?
> > +JOBS=	sysctl -n kern.smp.cpus
> >
> > Should be != if it's gonna be used, but it's not referenced anywhere else
> > that I can see.
>
> It's used in XARGS_CMD to provide a bit of parallelism in an effort to
> be a bit faster. 

That was pretty blind of me.

-- 
Mel
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch-lang-python-Makefile
Type: text/x-patch
Size: 1624 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-ports/attachments/20090610/2f8fc649/patch-lang-python-Makefile-0001.bin


More information about the freebsd-ports mailing list