pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Adrian Klaver <adrian.klaver@aklaver.com>
To: Travis Allison <travisallison@gmail.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Alvaro Herrera <alvherre@alvh.no-ip.org>
Cc: floriparob@gmail.com
Cc: pgsql-general@postgresql.org
Cc: Christoph Berg <myon@debian.org>
Subject: Re: What generates pg_config.h?
Date: Sat, 6 Jan 2018 07:24:28 -0800
Message-ID: <67591f85-a910-2e0b-1fdd-9c774eacd65f@aklaver.com> (raw)
In-Reply-To: <CAEJ64ta5QTU=fCUa-fBtGAr34jwQXoAiTcGf5p1oDRr_=rsMVw@mail.gmail.com>
References: <20180105212750.ip5ek6v4p3tiix7e@alvherre.pgsql>
	<20599.1515192990@sss.pgh.pa.us>
	<CAEJ64tb7j1XR009TVfaEeh1=gkRgZ5vJ=sqfQ3WFg38YDBm5dw@mail.gmail.com>
	<22433.1515194991@sss.pgh.pa.us>
	<52b48b90-159a-0341-23e1-e88e52daa86d@aklaver.com>
	<CAEJ64tYkb2jHcXGujKSNrr1MPrz=sGiQa=Ds_pjKH9mWUVuhOw@mail.gmail.com>
	<28314.1515211514@sss.pgh.pa.us>
	<CAEJ64ta5QTU=fCUa-fBtGAr34jwQXoAiTcGf5p1oDRr_=rsMVw@mail.gmail.com>

On 01/05/2018 09:36 PM, Travis Allison wrote:
> Tom, I guess I don't understand the point of having a different 
> pg_config.h in my user/include/postgresql directory than the postgresql 
> server that I am running.  You mentioned building client code that would 
> reference the pg_config.h in user/include/postgresql.  A couple of 
> questions:
> 
> What type of client code are you referring to?
> What is the point of having a pg_config.h for a server that I am not 
> even running?

Not Tom, but to answer:

As to client code, that would include the Postgres CLI client psql or 
the Python adapter psycopg2 among others. This code does not need to be 
on the server machine, it can be anywhere you want a client to connect 
to a Postgres server.

The point of a more recent pg_config.h is that client code compiled with 
it would be backwards compatible whereas compiling against an older 
version would result in code that would not work against newer servers.

The problem you are running into is that the build process is using both 
the older(9.6.5) and newer(10.0) pg_config.h at the same time.


> 
> Travis
> 
> 
> 
> 
> 
> On Fri, Jan 5, 2018 at 8:05 PM, Tom Lane <tgl@sss.pgh.pa.us 
> <mailto:tgl@sss.pgh.pa.us>> wrote:
> 
>     Travis Allison <travisallison@gmail.com
>     <mailto:travisallison@gmail.com>> writes:
>     > I suppose an easy workaround is to copy my version 9.6 pg_config.h into my
>     > user/include/postgresql directory and replace the one installed by
>     > libpq-dev.
> 
>     > Can you think of any detrimental side-effects from doing that?
> 
>     I would not recommend that: it's likely to break code that's expecting
>     the Ubuntu-standard layout.  I think your best course is to adapt the
>     particular package you're having trouble with to work with that layout.
>     Maybe contact its author for help?
> 
>                              regards, tom lane
> 
> 


-- 
Adrian Klaver
adrian.klaver@aklaver.com




view thread (18+ messages)  latest in thread

Message-ID: <67591f85-a910-2e0b-1fdd-9c774eacd65f@aklaver.com>
Permalink:  ../67591f85-a910-2e0b-1fdd-9c774eacd65f@aklaver.com/
Also on:    postgresql.org/message-id/67591f85-a910-2e0b-1fdd-9c774eacd65f@aklaver.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: adrian.klaver@aklaver.com, travisallison@gmail.com, tgl@sss.pgh.pa.us, alvherre@alvh.no-ip.org, floriparob@gmail.com, myon@debian.org
  Subject: Re: What generates pg_config.h?
  In-Reply-To: <67591f85-a910-2e0b-1fdd-9c774eacd65f@aklaver.com>
  References: <20180105212750.ip5ek6v4p3tiix7e@alvherre.pgsql> <20599.1515192990@sss.pgh.pa.us> <CAEJ64tb7j1XR009TVfaEeh1=gkRgZ5vJ=sqfQ3WFg38YDBm5dw@mail.gmail.com> <22433.1515194991@sss.pgh.pa.us> <52b48b90-159a-0341-23e1-e88e52daa86d@aklaver.com> <CAEJ64tYkb2jHcXGujKSNrr1MPrz=sGiQa=Ds_pjKH9mWUVuhOw@mail.gmail.com> <28314.1515211514@sss.pgh.pa.us> <CAEJ64ta5QTU=fCUa-fBtGAr34jwQXoAiTcGf5p1oDRr_=rsMVw@mail.gmail.com> <67591f85-a910-2e0b-1fdd-9c774eacd65f@aklaver.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox