How to disable staging support in ports tree universally?

Jeremy Chadwick jdc at koitsu.org
Sat Oct 12 05:59:55 UTC 2013


(Please keep me CC'd, as I am not subscribed to any FreeBSD lists)

Plain, simple, obvious question: how do I disable staging support in the
latest ports tree?

Today I rebuilt a port (which had been upgraded to remove NO_STAGE=yes
from it Makefile) as follows:

# make deinstall
# make clean install

...and proceeded to watch my /usr/ports filesystem I/O go through
the roof with unnecessary crap, starting about here:

===>  Staging for sudo-1.8.8
===>   Generating temporary packing list

...which is normal, except I suddenly start tons of disk I/O involving
$WRKDIR/stage, proceeded by this:

===>  Building package for sudo-1.8.8
Creating package /usr/ports/security/sudo/work/sudo-1.8.8.tbz
Registering depends:.
Creating bzip'd tar ball in '/usr/ports/security/sudo/work/sudo-1.8.8.tbz'

All of this comes from Mk/bsd.port.mk, per _STAGE_SEQ, which is preceded
by a plain and simple .if !defined(NO_STAGE).

I thought "okay, so just put NO_STAGE=yes in /etc/make.conf" but
make.conf(5) had no mention of this so I was wary.  Then I found these
two posts clearly stating "this is not a make.conf variable and things
will bust if you do that":

http://lists.freebsd.org/pipermail/freebsd-ports/2013-October/086692.html
http://lists.freebsd.org/pipermail/freebsd-ports/2013-October/086697.html

I tried it anyway (in a VM) -- yup, it sure does leave quite a mess
laying around if you set it globally, so definitely don't do that.

So I read /usr/ports/UPDATING, and /usr/ports/CHANGES, and this:

https://wiki.freebsd.org/ports/StageDir

...to no avail.

So how do I stop this staging nonsense when it doesn't apply to any of
my systems/environments?  I install third-party software directly from
the ports tree, I DO NOT USE pkg, nor do I ever plan on using pkg given
that I customise ports individually (through "make config" and some
make.conf knobs) quite heavily.

I want to know how to stop this excess waste of disk I/O when it doesn't
apply to my environments/systems, and I'm sure many others do as well.

-- 
| Jeremy Chadwick                                   jdc at koitsu.org |
| UNIX Systems Administrator                http://jdc.koitsu.org/ |
| Making life hard for others since 1977.             PGP 4BD6C0CB |



More information about the freebsd-ports mailing list