Subject: Pb using pkgsrc as unpriviledged user
To: None <netbsd-help@netbsd.org>
From: =?ISO-8859-1?Q?Judica=EBl_Courant?= <Judicael.Courant@free.fr>
List: netbsd-help
Date: 11/04/2005 15:32:08
Hello,

I am having hard times trying to install srcpkg as a non-priviledged
user under Debian GNU/Linux. Here is what I have done yet, and what is
still problematic:

* After a checkout, in bootstrap, I have launched ./bootstrap
--ignore-user-check
* I have added the following to my .bash_profile:
PATH=~/pkg/bin:$HOME/pkg/sbin:$PATH
MANPATH=$HOME/pkg/man:$MANPATH
export PATH
export MANPATH
export PKG_DBDIR=$HOME/pkg/var/db/pkg

(BTW, I have seen no explanation about adding PKG_DBDIR to the env, did
I miss anything?)

* Experiencing various troubles, I modified mk.conf as follows :
$ cvs diff mk.conf
Index: mk.conf
===================================================================
RCS file: /cvsroot/pkgsrc/mk/defaults/mk.conf,v
retrieving revision 1.84
diff -r1.84 mk.conf
171c171
< LOCALBASE?=   /usr/pkg
---
> LOCALBASE?=   /home/ports/pkg
181c181
< VARBASE?=     /var
---
> VARBASE?=     ${LOCALBASE}/var
1770c1770
< UNPRIVILEGED?= NO
---
> UNPRIVILEGED?= YES

* "bmake" in devel/libtool-base works fine (or seems to)

* "bmake install" in the same dir gives:
===> Installing for libtool-base-1.5.18nb5
Making install in .
test -z "/home/ports/pkg/bin" || mkdir -p -- "/home/ports/pkg/bin"
 /usr/bin/install -c -o root -g root -m 555 'libtool'
'/home/ports/pkg/bin/libtool'
/usr/bin/install: cannot change ownership of
`/home/ports/pkg/bin/libtool': Operation not permitted
 /usr/bin/install -c -o root -g root -m 555 'libtoolize'
'/home/ports/pkg/bin/libtoolize'
/usr/bin/install: cannot change ownership of
`/home/ports/pkg/bin/libtoolize': Operation not permitted
*** Error code 1

Stop.
bmake: stopped in /home/ports/pkgsrc/devel/libtool-base/work/libtool-1.5.18
*** Error code 1
[...]

Is this a bug of this particular port? Or did I do anything wrong?

Sincerly yours,

J. Courant.
-- 
Judicael.Courant@free.fr
Tel (+33) (0)8 703 702 88
GPG public key: 7C25 D439 9F60 BC68 A131  6267 98B9 98F6 7107 2457