Subject: Re: pkg/29200: .pkgdb not created if workdir already exists
To: None <pkg-manager@netbsd.org, gnats-admin@netbsd.org,>
From: Lasse Kliemann <lasse-list-netbsd-pkgsrc-bugs-2004@plastictree.net>
List: pkgsrc-bugs
Date: 02/04/2005 17:57:22
--Kj7319i9nmIyA2yE
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
> >Number: 29200
> >Category: pkg
> >Synopsis: .pkgdb not created if workdir already exists
> >Confidential: no
> >Severity: non-critical
> >Priority: medium
> >Responsible: pkg-manager
> >State: open
> >Class: sw-bug
> >Submitter-Id: net
> >Arrival-Date: Wed Feb 02 16:45:00 +0000 2005
> >Originator: lasse-sendpr-2005@plastictree.net
> >Release: pkgsrc-current
> >Environment:
> Trustix Secure Linux 2.2 on i386, but likely is not platform related
> >Description:
>=20
> As mentioned in pkg/29148, .pkgdb is not created if work directory alread=
y=20
> exists. Solution is to delete the workdir and restart the build. Unfortun=
ately,=20
> this does not work if workdir is accessed via a symbolic link.
>=20
> >How-To-Repeat:
>=20
> cd pkgsrc/pkgtools/digest
> bmake clean
> rm -fr "$HOME"/work
> mkdir "$HOME"/work # this step cannot be left out
> ln -s "$HOME"/work work
> bmake install
>=20
> >Fix:
>=20
> As a workaround, do not use symbolic links to access work directory.
I discovered a workaround that even allows using symbolic links. You can us=
e=20
WRKDIR_BASENAME as in the following example:
cd pkgsrc/pkgtools/digest
bmake clean
rm -fr "$HOME"/work
mkdir "$HOME"/work
ln -s "$HOME"/work work
WRKDIR_BASENAME=3Dwork/here
export WRKDIR_BASENAME
bmake install
I implemented this in my sepbuild package [1], which otherwise wouldn't wor=
k=20
with pkgsrc-current anymore.
Lasse
[1] http://plastictree.net/software/sepbuild
--Kj7319i9nmIyA2yE
Content-Type: application/pgp-signature
Content-Disposition: inline
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.6 (NetBSD)
iD8DBQFCA6lx1gObwed86AkRArMLAKCdATheltBgpPFYRDZlZtpJvR4DnQCfevbV
5pK6vjOFK8lA1d86t8g3C4k=
=8I27
-----END PGP SIGNATURE-----
--Kj7319i9nmIyA2yE--