Re: pg_migrator mention in documentation

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Bruce Momjian <bruce(at)momjian(dot)us>
Cc: Peter Eisentraut <peter_e(at)gmx(dot)net>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: pg_migrator mention in documentation
Date: 2009-07-03 17:05:04
Message-ID: 3176.1246640704@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Bruce Momjian <bruce(at)momjian(dot)us> writes:
> Tom Lane wrote:
>> Also, the recommendation to specify prefix here is redundant and
>> error-prone. It can get the correct prefix from pg_config.

> Again, see my email just posted about using pg_migrator in a
> multi-pg_config-binary environment.

What's your point? If the wrong pg_config is first in the path,
PGXS will do the wrong things anyway. Specifying install prefix
manually is not enough to prevent that.

If the pg_migrator makefiles conformed to the accepted syntax for
PGXS invocation (click click ... which they do now) then the preferred
solution for this would be to explicitly specify the pg_config
location, *and nothing else*, on the make command line.

gmake USE_PGXS=1 PG_CONFIG=/path/to/pg_config install

I'm inclined to agree with Peter that the current documentation
is just going to confuse people by giving them too many options.
I would agree with removing the "ifdef USE_PGXS" from the makefiles
so that the USE_PGXS=1 bit can go away, and then saying

If the new installation's pg_config is first in your path,
you can just say
gmake install
Otherwise, or to be extra sure, say
gmake PG_CONFIG=/path/to/pg_config install

(Although actually, if that pg_config isn't in your path, the
installed pg_migrator won't be either. It might be better to just
say "fix things so that the new installation's executables are
first in your PATH", and be done with it.)

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2009-07-03 17:16:37 Re: 8.5 development schedule
Previous Message Robert Haas 2009-07-03 16:15:54 Re: [HACKERS] commitfest.postgresql.org