Re: How to declare PG version for compiling extensions. - Mailing list pgsql-general

From Tom Lane
Subject Re: How to declare PG version for compiling extensions.
Date
Msg-id 82978.1540216976@sss.pgh.pa.us
Whole thread Raw
In response to How to declare PG version for compiling extensions.  (GPT <gptmailinglists@gmail.com>)
List pgsql-general
GPT <gptmailinglists@gmail.com> writes:
> Both PG versions 10.5 and 11 are installed.
> I have been trying to compile extensions for PG11 by using:
> PATH=/.../11/bin:PATH make USE_...
> but unfortunately PG10 is always being used (the `make` output always
> shows PG10 and refers to `pg_config`).

> 1) Does it have to do with pg_config?

If you're using PGXS, then yes, your makefile should be querying
pg_config to find out where Postgres' headers etc are installed.
You might want to check whether "pg_config --pgxs" points to the
correct place.  Also make sure your makefile is indeed doing
something like

PG_CONFIG = pg_config
PGXS := $(shell $(PG_CONFIG) --pgxs)
include $(PGXS)

and not just hard-wiring where to look.

            regards, tom lane


pgsql-general by date:

Previous
From: Adrian Klaver
Date:
Subject: Re: How to declare PG version for compiling extensions.
Next
From: Scot Kreienkamp
Date:
Subject: RE: Replication question