tech-pkg archive

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


"Filip Hajny" <> writes:

> On 18.12.2010, at 14:45, Adam wrote:
>>>> How about getting rid of PG_SUBPREFIX? :)
>>> I don't use it, but it makes having two postgres versions around for
>>> testing a lot easier.
>> People who love testing, know how to build and install PostgreSQL.
>> Average users don't need the black magic of PG_SUBPREFIX. I know some
>> packages expect libpq to be in PREFIX/lib, but PG_SUBPREFIX might
>> move it somewhere else. In my opinion it's dangerous, dirty and makes
>> maintaining the package more complicated.
> I disagree. It's not just about testing. A customer running a
> production site will be much more comfortable knowing that he can have
> both major versions installed at the same time, and only do away with
> the old one when he's safe knowing the import into the new one worked
> fine.
> I should say I did not know about the existence of PG_SUBPREFIX at all
> until this thread, and have been cursing at CONFLICTs all the time,
> wishing PostgreSQL support in pkgsrc had been writen the OpenSolaris
> way (i.e. each version having its own installation prefix + storage
> data directory). At the same time knowing the significant problems
> raised by such approach of course… ;)

This depends on whether installation is tied to PGUSER or not.
That is, if you can change PGHOME independently of PGUSER.
Try something like this in mk.conf:

.if $(PKGPATH) == "databases/postgresql83-server"
PGHOME= /var/db/pg83
.if $(PKGPATH) == "databases/postgresql84-server"
PGHOME= /var/db/pg84
.if $(PKGPATH) == "databases/postgresql90-server"
PGHOME= /var/db/pg90

It may be that other parameters may need tweaking.

As for original problem, it will be nice, if users ask questions aloud
rather than keep them to themselves.


Home | Main Index | Thread Index | Old Index