Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 19 May 2005 23:45:32 +0200
From:      Oliver Lehmann <lehmann@ans-netz.de>
To:        Alfred Perlstein <alfred@freebsd.org>
Cc:        ports@freebsd.org
Subject:   Re: building/testing ports as non-root
Message-ID:  <20050519234532.76fbede0.lehmann@ans-netz.de>
In-Reply-To: <20050519213551.GB46880@elvis.mu.org>
References:  <20050519213551.GB46880@elvis.mu.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Alfred Perlstein wrote:

> How do people here usually test/build ports when they do not
> have root on a box?
> 
> I have this...
> 
> any suggestions to make it better?
> 

I'm using a mix of dirty hacks:


oliver@freefall oliver> cat build_env
#!/bin/csh
setenv PATH /sbin:/bin:/usr/sbin:/usr/bin:/usr/games:/home/oliver/root/
usr/X11R6/bin:/home/oliver/root/usr/local/bin
setenv MAKEFLAGS "-m/home/oliver/root/usr/share/mk/`uname -r | cut -d'.' -
f1` -DINSTALL_AS_USER"
setenv MAKECONF /home/oliver/root/etc/make.conf
setenv PKG_DBDIR /home/oliver/root/var/db/pkg
ldconfig -if /home/oliver/root/ld-elf.so.hints /usr/lib /home/oliver/root/
usr/X11R6/lib /home/oliver/root/usr/local/lib
oliver@freefall oliver> tail root/usr/share/mk/6/sys.mk

LOCALBASE=      ${HOME}/root/usr/local
X11BASE=        ${HOME}/root/usr/X11R6
#PREFIX?=       ${LOCALBASE}
DISTDIR=        ${HOME}/root/usr/distfiles
PORT_DBDIR=     ${HOME}/root/var/db/ports
PKG_DBDIR=      ${HOME}/root/var/db/pkg
WRKDIRPREFIX=   ${HOME}/obj/${MACHINE}-${OSREL}
INSTALL_AS_USER=yo
LDCONFIG="${HOME}/root/ldconfig"
oliver@freefall oliver> cat root/ldconfig
/sbin/ldconfig -i -f /home/oliver/root/ld-elf.so.hints $*
oliver@freefall oliver> grep 'OWN.*oliver' root/usr/share/mk/6/bsd.*
root/usr/share/mk/6/bsd.own.mk:BINOWN?=	oliver
root/usr/share/mk/6/bsd.own.mk:SHAREOWN?=	oliver


then "source build_env" and start using the ports...
some things truly can be sorted out from sys.mk into make.conf and so on
but I just didn't wanted to spend more time in cleaning it up.

-- 
 Oliver Lehmann
  http://www.pofo.de/
  http://wishlist.ans-netz.de/



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050519234532.76fbede0.lehmann>