Subject: everything OK with mksandbox and bulk builds?
To: None <tech-pkg@netbsd.org>
From: Jeff Rizzo <riz@boogers.sf.ca.us>
List: tech-pkg
Date: 05/08/2003 15:19:31
This is, admittedly, my first attempt at doing bulk builds
in a sandbox environment, so most likely I've screwed something up...

I ran "mksandbox" and created a sandbox build environment
for packages - seemed to work fine, and now I have a bunch
of null mounts.

Then, I added the following to /etc/mk.conf in the sandbox:
PACKAGES?=      ${_PKGSRCDIR}/packages/${MACHINE_ARCH}
WRKOBJDIR?=     /var/tmp/pkgsrc
BSDSRCDIR=      /usr/src
BSDXSRCDIR=     /usr/xsrc
OBJHOSTNAME?=   yes
FAILOVER_FETCH= yes
PKG_DEVELOPER?= yes
_ACCEPTABLE=    yes
BULK_PREREQ+=   pkgtools/xpkgwedge

Then, I chroot'ed to the sandbox, cd-ed into /usr/pkgsrc, and
ran "sh mk/bulk/build" as Packages.txt indicates.  However,
something doesn't appear to be picking up ${_PKGSRCDIR} correctly,
because it dies very soon into the build, at what appears to
be the first attempt to build a package that is _not_ in BULK_PREREQ:

[extra stuff elided]
Creating gzip'd tar ball in '/usr/pkgsrc/packages/i386/All/xpkgwedge-1.7.tgz'
BULK> Cleaning packages and its depends
make clean CLEANDEPENDS=YES
===> Cleaning for xpkgwedge-1.7
pkgtools/digest
BULK> /usr/pkgsrc/packages/i386/All/digest-20021220.tgz is up to date.
BULK> Installing BULK_PREREQ packages
cd /pkgtools/xpkgwedge && make bulk-install
cd: can't cd to /pkgtools/xpkgwedge
*** Error code 2

Stop.
make: stopped in /usr/pkgsrc
mk/bulk/build: Cache creation failed.  Aborting build.
#

...as you can see, it doesn't seem to have the correct pkgsrc dir
when it attempts to "cd /pkgtools/xpkgwedge && make bulk-install".
From what I can glean from /usr/pkgsrc/mk/bulk/build, it's trying
to cd to "${_PKGSRCDIR}/pkgtools/xpkgwedge, and ${_PKGSRCDIR}
seems to be empty.

Can anyone give me a clue?

Thanks,
+j


-- 
Jeff Rizzo                                         http://boogers.sf.ca.us/~riz