Port make extract: /usr/ports or /var/ports/usr/ports?

Greetings, All!

I have access to several FreeBSD machines. I've noticed, that on some hosts doing make extract (or make package), while current working directory is /usr/ports/foo/bar, will create /usr/ports/foo/bar/work, whereas on other hosts it will use /var/ports/usr/ports/foo/bar. What controls this behaviour? Why it is different amongst different hosts? Is there a document describing this? Thanks!
 
maybe this will help

#extract - Unpacks ${DISTFILES} into ${WRKDIR}.

${WRKDIR} - A Temporary working directory that gets *clobbered* on clean Default: ${WRKDIRPREFIX}$.{CURDIR}/work

WRKDIRPREFIX - The place to root the temporary working directory hierarchy. This path must *not* end in '/' Default: none
https://www.freebsd.org/doc/en/books/porters-handbook/porting-wrkdirprefix.html

ports(7)

ENVIRONMENT

PORTSDIR Location of the ports tree. This is /usr/ports on FreeBSD
and OpenBSD, and /usr/pkgsrc on NetBSD.

WRKDIRPREFIX Where to create any temporary files. Useful if PORTSDIR is
read-only (perhaps mounted from a CD-ROM).


You can check /etc/make.conf if there's any WRKDIRPREFIX there.
 
Back
Top