NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

/usr/pkg and unprivileged pkgsrc in parallel



Hi!

I am using pkgsrc on several NetBSD machines the "native way", i.e.
compiling in /usr/pkgsrc, installing to /usr/pkg and configuration in
/etc/mk.conf.

Now I want to add an unprivileged installation, that I want to
distribute via NFS (hence the question regarding symlinks the other
day, as they appear when using amd). The source directory is

/vol/pkgsrc/20190803/pkgsrc

and I bootstrap with

$ ./bootstrap --prefix /vol/pkg/20190803 --unprivileged

I remove /usr/pkg/bin and /usr/pkg/sbin from PATH and instead add
/vol/pkg/20190803/bin and /vol/pkg/20190803/sbin (before /usr/sbin).

When installing a single package from its source directory, everything
goes into the right place. But I noticed that calling

$ pkg_chk -aun

in /vol/pkgsrc/20190803/pkgsrc will pick up both the pkgchk.conf in
that directory, but also /usr/pkgsrc/pkgchk.conf. This is easily fixed
using "-C". In addition, I get "has binary package", because pkg_chk
detects them in /usr/pkgsrc/packages. Installing these to
/vol/pkg/20190803 would be fatal, of course. According to pkg_chk's
manpage, the default path for binary packages is PACKAGES if PKGSRCDIR
is available. These are

$ bmake show-var VARNAME=PACKAGES
/export/dk3/pkgsrc/20190803/pkgsrc/packages
$ bmake show-var VARNAME=PKGSRCDIR
/export/dk3/pkgsrc/20190803/pkgsrc

i.e. (although symlink-resolved) the correct paths. I use pkg_chk with
"-s" anyway, but this leaves me wondering if there are other
situations where the two pkgsrc installation might get mixed up. Or
are these bugs only in pkgtools/pkg_chk? Does anybody use such a
scenario?

Thanks,
   Joern

-- 
Joern Clausen
https://www.oe-files.de/photography/


Home | Main Index | Thread Index | Old Index