tech-pkg archive

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

Re: changing the default pkgdbdir used in bootstrap script

Greg Troxel <> writes:

> "Sevan / Venture37" <> writes:
>> On the other BSDs in the family where pkgsrc is not the primary /
>> native packaging system there is a conflict over the usage of the pkg
>> directory.
>> Rather than trying to deal with these platforms on a case by case
>> basis to override this setting & use an alternative directory, any
>> objection to using a different name by default??
>> -[ -z "$pkgdbdir" ] && pkgdbdir=${varbase}/db/pkg
>> +[ -z "$pkgdbdir" ] && pkgdbdir=${varbase}/db/pkgsrc
> I think Hubert's suggestion of LOCALBASE has merit.
> Also, if /var/db/pkg is going to be avoided by changing to
> /var/db/pkgsrc, then /usr/pkg should also be avoided.  If the db is in
> LOCALBASE, then this is moot.
> What are the downsides of using a db under LOCALBASE on platforms where
> pkgsrc is not native?

I think, we have come to consensus on this point, actually. To reiterate...

It isn't clear why PKG_DBDIR has ended under VARBASE in the first place.
I'd call it a bug, since PKG_DBDIR is not a database in its conventional sense.
It is metadata of LOCALBASE rather. As such, it is better if PKG_DBDIR is
attached to LOCALBASE in one or another way. You only modify PKG_DBDIR
when you modify LOCALBASE, and you don't need and don't want to modify it,
when you don't touch LOCALBASE.

Besides, moving PKG_DBDIR into LOCALBASE will simplify documentation and
help a lot of people not to trip over related problems over and over again.

The only point of contention right now is how this directory should be
named and where to put it within LOCALBASE. I use to call to put it as
$PREFIX/pkgdb, but I'm not attached to that name. Yet I'd prefer not to
have its name starting with dot. (I consider "pollution" point being
moot since we install a lot of software into its own subdirectory or
subprefix under LOCALBASE.)

And the last, I'd like to move PKG_DBDIR out of /var in NetBSD base too,
but that's a lot harder than changing default for bootstrapped deployments.


Home | Main Index | Thread Index | Old Index