Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 21 Jul 2011 19:39:45 +0100
From:      Bruce Cran <bruce@cran.org.uk>
To:        Daniel Staal <DStaal@usa.net>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: build ports from not a root user?
Message-ID:  <4E287271.2050204@cran.org.uk>
In-Reply-To: <321f591217b15bbbb3b936fcfffd6c2f.squirrel@www.magehandbook.com>
References:  <20110721100259.GA5326@external.screwed.box> <80674226c5ead62b213864dcd36b6a75.squirrel@www.magehandbook.com> <20110721153050.GA76083@external.screwed.box> <bd3d6dc9b6b0040d29f741cc94972b02.squirrel@www.magehandbook.com> <20110721175420.GF7553@external.screwed.box> <ae4d7343fa3e423e433ddcbd0cabda2c.squirrel@www.magehandbook.com> <20110721182642.GG7553@external.screwed.box> <321f591217b15bbbb3b936fcfffd6c2f.squirrel@www.magehandbook.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On 21/07/2011 19:31, Daniel Staal wrote:
> On Thu, July 21, 2011 2:26 pm, Peter Vereshagin wrote:
>> Oh Daniel want you buy me a mersedes benz?
>> 2011/07/21 14:01:04 -0400 Daniel Staal<DStaal@usa.net>  =>  To
>> freebsd-questions@freebsd.org :
>> DS>  Ok, then I've already answered your question several emails ago.  The
>> DS>  ports system will do this automatically with a simple 'make', 'make
>> DS>  install', or 'make depends; make install'.  And you said you knew
>> about
>>
>> No it doesn't.
>>
>> 'all' target includes 'depends' target.
>> 'depends' target includes performing 'make install' on the dependencies
>> which
>> I'd like to avoid.
>>
>> This can be avoided if a some tool like the portupgrade has did them
>> already.
>> It can do it that same way, too: build as a non-root user and then install
>> as a
>> root user.
>>
>> That way the 'make depends' can be done as a non-root user as it's a no-op
>> additional check.
> So you want to install software without installing it's dependencies
> first?  Or build software without installing it's build dependencies
> first?

The easiest way to build ports under a non-privileged user is probably 
to use portmaster (ports-mgmt/portmaster): it has a PM_SU_CMD which is 
normally set to /usr/local/bin/sudo which it uses whenever it needs to 
elevate to root.

-- 
Bruce Cran



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