Why does pg_standby require libpq.so.5?

Started by Fujii Masaoover 16 years ago10 messages
#1Fujii Masao
masao.fujii@gmail.com
1 attachment(s)

Hi,

I wonder why pg_standby requires libpq.so.5. We should get rid of
PG_LIB settings from contrib/pg_standby/Makefile? Here is the patch
to do so.

Am I missing something?

Regards,

--
Fujii Masao
NIPPON TELEGRAPH AND TELEPHONE CORPORATION
NTT Open Source Software Center

Attachments:

pgstandby_makefile.patchtext/x-patch; charset=US-ASCII; name=pgstandby_makefile.patchDownload
Index: contrib/pg_standby/Makefile
===================================================================
RCS file: /projects/cvsroot/pgsql/contrib/pg_standby/Makefile,v
retrieving revision 1.4
diff -c -r1.4 Makefile
*** contrib/pg_standby/Makefile	10 Nov 2007 23:59:51 -0000	1.4
--- contrib/pg_standby/Makefile	25 Jun 2009 04:39:38 -0000
***************
*** 4,10 ****
  OBJS	= pg_standby.o
  
  PG_CPPFLAGS = -I$(libpq_srcdir)
- PG_LIBS = $(libpq_pgport)
  
  ifdef USE_PGXS
  PG_CONFIG = pg_config
--- 4,9 ----
#2Simon Riggs
simon@2ndQuadrant.com
In reply to: Fujii Masao (#1)
Re: Why does pg_standby require libpq.so.5?

On Thu, 2009-06-25 at 13:50 +0900, Fujii Masao wrote:

I wonder why pg_standby requires libpq.so.5. We should get rid of
PG_LIB settings from contrib/pg_standby/Makefile? Here is the patch
to do so.

Am I missing something?

It's good. Checked and ready to apply.

--
Simon Riggs www.2ndQuadrant.com
PostgreSQL Training, Services and Support

#3Magnus Hagander
magnus@hagander.net
In reply to: Simon Riggs (#2)
Re: Why does pg_standby require libpq.so.5?

Simon Riggs wrote:

On Thu, 2009-06-25 at 13:50 +0900, Fujii Masao wrote:

I wonder why pg_standby requires libpq.so.5. We should get rid of
PG_LIB settings from contrib/pg_standby/Makefile? Here is the patch
to do so.

Am I missing something?

It's good. Checked and ready to apply.

Is there any reason not to remove the include directory in PG_CPPFLAGS
as well? Seems it is equally unused...

--
Magnus Hagander
Self: http://www.hagander.net/
Work: http://www.redpill-linpro.com/

#4Fujii Masao
masao.fujii@gmail.com
In reply to: Magnus Hagander (#3)
Re: Why does pg_standby require libpq.so.5?

Hi,

On Thu, Jun 25, 2009 at 8:33 PM, Magnus Hagander<magnus@hagander.net> wrote:

Is there any reason not to remove the include directory in PG_CPPFLAGS
as well? Seems it is equally unused...

No. I agree to remove PG_CPPFLAGS.

Regards,

--
Fujii Masao
NIPPON TELEGRAPH AND TELEPHONE CORPORATION
NTT Open Source Software Center

#5Magnus Hagander
magnus@hagander.net
In reply to: Fujii Masao (#4)
Re: Why does pg_standby require libpq.so.5?

Fujii Masao wrote:

Hi,

On Thu, Jun 25, 2009 at 8:33 PM, Magnus Hagander<magnus@hagander.net> wrote:

Is there any reason not to remove the include directory in PG_CPPFLAGS
as well? Seems it is equally unused...

No. I agree to remove PG_CPPFLAGS.

The second question is, is it worth doing this so extremely late in the
8.4 development? After mentioning it quickly in an offlist discussion
with Heikki, I think our conclusion was that we should wait with this
until the tree opens for 8.5. It's not a very likely scenario that
anybody actually has pg_standby on a machine that doesn't have libpq on
it - since it needs to have a PostgreSQL server on it to make any sense....

--
Magnus Hagander
Self: http://www.hagander.net/
Work: http://www.redpill-linpro.com/

#6Heikki Linnakangas
heikki.linnakangas@enterprisedb.com
In reply to: Magnus Hagander (#5)
Re: Why does pg_standby require libpq.so.5?

Magnus Hagander wrote:

Fujii Masao wrote:

On Thu, Jun 25, 2009 at 8:33 PM, Magnus Hagander<magnus@hagander.net> wrote:

Is there any reason not to remove the include directory in PG_CPPFLAGS
as well? Seems it is equally unused...

No. I agree to remove PG_CPPFLAGS.

The second question is, is it worth doing this so extremely late in the
8.4 development? After mentioning it quickly in an offlist discussion
with Heikki, I think our conclusion was that we should wait with this
until the tree opens for 8.5. It's not a very likely scenario that
anybody actually has pg_standby on a machine that doesn't have libpq on
it - since it needs to have a PostgreSQL server on it to make any sense....

Right, let's put this on the first 8.5 commitfest page. It's not a
regression and it's harmless in practice.

--
Heikki Linnakangas
EnterpriseDB http://www.enterprisedb.com

#7Tom Lane
tgl@sss.pgh.pa.us
In reply to: Magnus Hagander (#5)
Re: Why does pg_standby require libpq.so.5?

Magnus Hagander <magnus@hagander.net> writes:

The second question is, is it worth doing this so extremely late in the
8.4 development? After mentioning it quickly in an offlist discussion
with Heikki, I think our conclusion was that we should wait with this
until the tree opens for 8.5.

+1. This is barely even a bug; it's not worth taking any risk for at
this point. (It is already too late for a patch applied now to be
tested by the whole buildfarm before we wrap 8.4.0 --- some machines
are on a once-a-day cycle.)

regards, tom lane

#8Magnus Hagander
magnus@hagander.net
In reply to: Tom Lane (#7)
1 attachment(s)
Re: Why does pg_standby require libpq.so.5?

Tom Lane wrote:

Magnus Hagander <magnus@hagander.net> writes:

The second question is, is it worth doing this so extremely late in the
8.4 development? After mentioning it quickly in an offlist discussion
with Heikki, I think our conclusion was that we should wait with this
until the tree opens for 8.5.

+1. This is barely even a bug; it's not worth taking any risk for at
this point. (It is already too late for a patch applied now to be
tested by the whole buildfarm before we wrap 8.4.0 --- some machines
are on a once-a-day cycle.)

Yeah, that was our reasoning as well.

Attached is a patch that takes them both away, so I have something to
put on the wiki :-)

--
Magnus Hagander
Self: http://www.hagander.net/
Work: http://www.redpill-linpro.com/

Attachments:

pg_standby_link.patchtext/x-diff; name=pg_standby_link.patchDownload
Index: Makefile
===================================================================
RCS file: /cvsroot/pgsql/contrib/pg_standby/Makefile,v
retrieving revision 1.4
diff -c -r1.4 Makefile
*** Makefile	10 Nov 2007 23:59:51 -0000	1.4
--- Makefile	25 Jun 2009 13:32:08 -0000
***************
*** 3,11 ****
  PROGRAM = pg_standby
  OBJS	= pg_standby.o
  
- PG_CPPFLAGS = -I$(libpq_srcdir)
- PG_LIBS = $(libpq_pgport)
- 
  ifdef USE_PGXS
  PG_CONFIG = pg_config
  PGXS := $(shell $(PG_CONFIG) --pgxs)
--- 3,8 ----
#9Fujii Masao
masao.fujii@gmail.com
In reply to: Magnus Hagander (#5)
Re: Why does pg_standby require libpq.so.5?

Hi,

On Thu, Jun 25, 2009 at 10:09 PM, Magnus Hagander<magnus@hagander.net> wrote:

The second question is, is it worth doing this so extremely late in the
8.4 development? After mentioning it quickly in an offlist discussion
with Heikki, I think our conclusion was that we should wait with this
until the tree opens for 8.5.

That's OK. I'll wait for 8.5.

It's not a very likely scenario that
anybody actually has pg_standby on a machine that doesn't have libpq on
it - since it needs to have a PostgreSQL server on it to make any sense....

My first concern was whether the latest pg_standby can work with old postgres
(old libpq.so).

Regards,

--
Fujii Masao
NIPPON TELEGRAPH AND TELEPHONE CORPORATION
NTT Open Source Software Center

#10Heikki Linnakangas
heikki.linnakangas@enterprisedb.com
In reply to: Fujii Masao (#9)
Re: Why does pg_standby require libpq.so.5?

Committed.

Fujii Masao wrote:

Hi,

On Thu, Jun 25, 2009 at 10:09 PM, Magnus Hagander<magnus@hagander.net> wrote:

The second question is, is it worth doing this so extremely late in the
8.4 development? After mentioning it quickly in an offlist discussion
with Heikki, I think our conclusion was that we should wait with this
until the tree opens for 8.5.

That's OK. I'll wait for 8.5.

It's not a very likely scenario that
anybody actually has pg_standby on a machine that doesn't have libpq on
it - since it needs to have a PostgreSQL server on it to make any sense....

My first concern was whether the latest pg_standby can work with old postgres
(old libpq.so).

Regards,

--
Heikki Linnakangas
EnterpriseDB http://www.enterprisedb.com