Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 9 Jun 2012 08:21:34 +0200
From:      Polytropon <freebsd@edvax.de>
To:        freebsd@dreamchaser.org
Cc:        FreeBSD Mailing List <freebsd-questions@freebsd.org>
Subject:   Re: prune ports tree?
Message-ID:  <20120609082134.42a36d30.freebsd@edvax.de>
In-Reply-To: <4FD2E7EF.1060208@dreamchaser.org>
References:  <4FD2E7EF.1060208@dreamchaser.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, 09 Jun 2012 00:06:39 -0600, Gary Aitken wrote:
> Is it possible to specify that parts of the ports tree should never be used?

How do you want to understand by "parts" and "not used"?

The easiest way to "not use" some part of the ports tree is to
remove that part. You can do that by manually deleting the port(s)
and even omitting them when updating your ports tree.

If you use csup, you can make /etc/sup/ports.sup like this:
Don't use ports-all, but only list the categories you want to
have updated. This works category-wise. You'll find examples
in /usr/share/examples/cvsup/ports-supfile which you can use
as a template for your own configuration file.

An example of /etc/sup/ports.sup could look like this:

	*default host=cvsup.freebsd.org
	*default base=/var/db
	*default prefix=/usr
	*default release=cvs tag=.
	*default delete use-rel-suffix
	*default compress
	ports-base
	ports-accessibility
	#ports-arabic
	ports-archivers
		[ ... list shortened ... ]
	ports-x11-servers
	ports-x11-themes
	ports-x11-toolkits
	ports-x11-wm

Only the listed ports categories will be updated.

Then you can add this to /etc/make.conf:

	SUP=		/usr/bin/csup		<---
	SUP_UPDATE=	/usr/bin/csup		<---
	SUPFLAGS=	-L 2			<---
	SUPHOST=	cvsup.freebsd.org
	SUPFILE=	/etc/sup/stable.sup
	PORTSSUPFILE=	/etc/sup/ports.sup	<---
	DOCSUPFILE=	/etc/sup/doc.sup
	DOC_LANG=	en_US.ISO8859-1 de_DE.ISO8859-1

The important lines are marked with a <---. Now you can do
this:

	# cd /usr/ports
	# make update

and you'll get the latest ports tree _excluding_ what you have
already removed.

You can also use /usr/ports/.cvsignore to specify the directories
csup should ignore; defaults are "distfiles" and "packages".
You can list "offending" ports here.

This approach does _not_ work well when using portsnap. From
the portsnap.conf manpage: "Note that operating with an incomplete
ports tree is not supported and may cause unexpected results."




-- 
Polytropon
Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...



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