Re: [PATCHES] [BUGS] BUG #1219: pgxs does not work fully

2004-08-28 Thread Bruce Momjian

Patch applied.  Thanks.

---


Fabien COELHO wrote:
 
  Am Dienstag, 17. August 2004 14:26 schrieb Fabien COELHO:
   The patch adds missing the libpgport.a file to the installation under
   install-all-headers. It is needed by some contribs. I install the
   library in pkglibdir, but I was wondering whether it should be libdir?
 
  Yes it should.  Please change it.
 
 Dear Peter, dear patchers,
 
 Please find attached a small patch against current CVS head that fixes
 pgport library installation so that it goes to libdir instead of
 pkglibdir. It works for me.
 
 Have a nice day,
 
 -- 
 Fabien Coelho - [EMAIL PROTECTED]

Content-Description: 

[ Attachment, skipping... ]

 
 ---(end of broadcast)---
 TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]

-- 
  Bruce Momjian|  http://candle.pha.pa.us
  [EMAIL PROTECTED]   |  (610) 359-1001
  +  If your life is a hard drive, |  13 Roberts Road
  +  Christ can be your backup.|  Newtown Square, Pennsylvania 19073

---(end of broadcast)---
TIP 5: Have you checked our extensive FAQ?

   http://www.postgresql.org/docs/faqs/FAQ.html


Re: [PATCHES] [BUGS] BUG #1219: pgxs does not work fully

2004-08-24 Thread Peter Eisentraut
Am Dienstag, 17. August 2004 14:26 schrieb Fabien COELHO:
 The patch adds missing the libpgport.a file to the installation under
 install-all-headers. It is needed by some contribs. I install the
 library in pkglibdir, but I was wondering whether it should be libdir?

Yes it should.  Please change it.

-- 
Peter Eisentraut
http://developer.postgresql.org/~petere/

---(end of broadcast)---
TIP 3: if posting/reading through Usenet, please send an appropriate
  subscribe-nomail command to [EMAIL PROTECTED] so that your
  message can get through to the mailing list cleanly


Re: [PATCHES] [BUGS] BUG #1219: pgxs does not work fully

2004-08-24 Thread Fabien COELHO

 Am Dienstag, 17. August 2004 14:26 schrieb Fabien COELHO:
  The patch adds missing the libpgport.a file to the installation under
  install-all-headers. It is needed by some contribs. I install the
  library in pkglibdir, but I was wondering whether it should be libdir?

 Yes it should.  Please change it.

Dear Peter, dear patchers,

Please find attached a small patch against current CVS head that fixes
pgport library installation so that it goes to libdir instead of
pkglibdir. It works for me.

Have a nice day,

-- 
Fabien Coelho - [EMAIL PROTECTED]*** ./src/Makefile.global.in.orig   Mon Aug 23 09:15:09 2004
--- ./src/Makefile.global.inTue Aug 24 15:21:17 2004
***
*** 360,366 
  LIBS := -lpgport $(LIBS)
  ifdef PGXS
  # where libpgport.a is installed
! LDFLAGS := -L$(pkglibdir) $(LDFLAGS)
  else
  LDFLAGS := -L$(top_builddir)/src/port $(LDFLAGS)
  endif
--- 360,366 
  LIBS := -lpgport $(LIBS)
  ifdef PGXS
  # where libpgport.a is installed
! LDFLAGS := -L$(libdir) $(LDFLAGS)
  else
  LDFLAGS := -L$(top_builddir)/src/port $(LDFLAGS)
  endif
*** ./src/port/Makefile.origMon Aug 23 09:15:10 2004
--- ./src/port/Makefile Tue Aug 24 15:18:08 2004
***
*** 22,31 
  
  # libpgport is needed by some contrib
  install-all-headers: 
!   $(INSTALL_STLIB) libpgport.a $(DESTDIR)$(pkglibdir)
  
  uninstall:
!   $(RM) $(DESTDIR)$(pkglibdir)/libpgport.a
  
  libpgport.a: $(LIBOBJS)
$(AR) $(AROPT) $@ $^
--- 22,31 
  
  # libpgport is needed by some contrib
  install-all-headers: 
!   $(INSTALL_STLIB) libpgport.a $(DESTDIR)$(libdir)
  
  uninstall:
!   $(RM) $(DESTDIR)$(libdir)/libpgport.a
  
  libpgport.a: $(LIBOBJS)
$(AR) $(AROPT) $@ $^

---(end of broadcast)---
TIP 2: you can get off all lists at once with the unregister command
(send unregister YourEmailAddressHere to [EMAIL PROTECTED])


Re: [PATCHES] [BUGS] BUG #1219: pgxs does not work fully

2004-08-20 Thread Bruce Momjian

Patch applied.  Thanks.

---


pgman wrote:
 
 Your patch has been added to the PostgreSQL unapplied patches list at:
 
   http://momjian.postgresql.org/cgi-bin/pgpatches
 
 It will be applied as soon as one of the PostgreSQL committers reviews
 and approves it.
 
 ---
 
 
  Please find enclose a submission to fix these problems.
  
  The patch adds missing the libpgport.a file to the installation under
  install-all-headers. It is needed by some contribs. I install the
  library in pkglibdir, but I was wondering whether it should be libdir?
  I was wondering also whether it would make sense to have a libpgport.so?
  
  It fixes various macros which are used by contrib makefiles, especially
  libpq_*dir and LDFLAGS when used under PGXS. It seems to me that they are
  needed to
  
  It adds the ability to test and use PGXS with contribs, with make
  USE_PGXS=1. Without the macro, this is exactly as before, there should be
  no difference, esp. wrt the vpath feature that seemed broken by previous
  submission. So it should not harm anybody, and it is useful at least to me.
  
  It fixes some inconsistencies in various contrib makefiles
  (useless override, := instead of =).
  
  It works for me. it validates.
  
  I'm available to fix any problem with this patch.
  
  Have a nice day,
 
 -- 
   Bruce Momjian|  http://candle.pha.pa.us
   [EMAIL PROTECTED]   |  (610) 359-1001
   +  If your life is a hard drive, |  13 Roberts Road
   +  Christ can be your backup.|  Newtown Square, Pennsylvania 19073

 *** ./contrib/btree_gist/Makefile.origFri May 28 15:09:43 2004
 --- ./contrib/btree_gist/Makefile Tue Aug 17 11:54:08 2004
 ***
 *** 1,8 
   
 - subdir = contrib/btree_gist
 - top_builddir = ../..
 - include $(top_builddir)/src/Makefile.global
 - 
   MODULE_big  = btree_gist
   
   OBJS= btree_gist.o btree_utils_num.o btree_utils_var.o btree_int2.o 
 btree_int4.o btree_int8.o \
 --- 1,4 
 ***
 *** 16,19 
 --- 12,23 
   REGRESS = init int2 int4 int8 float4 float8 cash oid timestamp timestamptz 
 time timetz \
 date interval macaddr inet cidr text varchar char bytea bit varbit 
 numeric
   
 + ifdef USE_PGXS
 + PGXS = $(shell pg_config --pgxs)
 + include $(PGXS)
 + else
 + subdir = contrib/btree_gist
 + top_builddir = ../..
 + include $(top_builddir)/src/Makefile.global
   include $(top_srcdir)/contrib/contrib-global.mk
 + endif
 *** ./contrib/chkpass/Makefile.orig   Sat Nov 29 20:51:19 2003
 --- ./contrib/chkpass/MakefileTue Aug 17 11:54:08 2004
 ***
 *** 1,13 
   # $PostgreSQL: pgsql-server/contrib/chkpass/Makefile,v 1.5 2003/11/29 19:51:19 
 pgsql Exp $
   
 - subdir = contrib/chkpass
 - top_builddir = ../..
 - include $(top_builddir)/src/Makefile.global
 - 
   MODULE_big = chkpass
   OBJS = chkpass.o
   SHLIB_LINK = $(filter -lcrypt, $(LIBS))
   DATA_built = chkpass.sql
   DOCS = README.chkpass
   
   include $(top_srcdir)/contrib/contrib-global.mk
 --- 1,17 
   # $PostgreSQL: pgsql-server/contrib/chkpass/Makefile,v 1.5 2003/11/29 19:51:19 
 pgsql Exp $
   
   MODULE_big = chkpass
   OBJS = chkpass.o
   SHLIB_LINK = $(filter -lcrypt, $(LIBS))
   DATA_built = chkpass.sql
   DOCS = README.chkpass
   
 + ifdef USE_PGXS
 + PGXS = $(shell pg_config --pgxs)
 + include $(PGXS)
 + else
 + subdir = contrib/chkpass
 + top_builddir = ../..
 + include $(top_builddir)/src/Makefile.global
   include $(top_srcdir)/contrib/contrib-global.mk
 + endif
 *** ./contrib/cube/Makefile.orig  Sat Nov 29 20:51:21 2003
 --- ./contrib/cube/Makefile   Tue Aug 17 11:54:08 2004
 ***
 *** 1,9 
   # $PostgreSQL: pgsql-server/contrib/cube/Makefile,v 1.11 2003/11/29 19:51:21 pgsql 
 Exp $
   
 - subdir = contrib/cube
 - top_builddir = ../..
 - include $(top_builddir)/src/Makefile.global
 - 
   MODULE_big = cube
   OBJS= cube.o cubeparse.o
   
 --- 1,5 
 ***
 *** 11,16 
 --- 7,25 
   DOCS = README.cube
   REGRESS = cube
   
 + EXTRA_CLEAN = cubeparse.c cubeparse.h cubescan.c y.tab.c y.tab.h
 + 
 + 
 + ifdef USE_PGXS
 + PGXS = $(shell pg_config --pgxs)
 + include $(PGXS)
 + else
 + subdir = contrib/cube
 + top_builddir = ../..
 + include $(top_builddir)/src/Makefile.global
 + include $(top_srcdir)/contrib/contrib-global.mk
 + endif
 + 
   
   # cubescan is compiled as part of cubeparse
   cubeparse.o: cubescan.c
 ***
 *** 32,39 
   else
   @$(missing) flex $ $@
   endif
 - 
 - EXTRA_CLEAN = cubeparse.c cubeparse.h cubescan.c y.tab.c y.tab.h
 - 
 - 
 - include $(top_srcdir)/contrib/contrib-global.mk
 --- 41,43 
 *** ./contrib/dbase/Makefile.orig Sat Nov 29 20:51:22 2003
 --- ./contrib/dbase/Makefile  Tue Aug 17 11:54:08 2004
 ***
 *** 1,9 
   # $PostgreSQL: 

Re: [PATCHES] [BUGS] BUG #1219: pgxs does not work fully

2004-08-17 Thread Fabien COELHO

Please find enclose a submission to fix these problems.

The patch adds missing the libpgport.a file to the installation under
install-all-headers. It is needed by some contribs. I install the
library in pkglibdir, but I was wondering whether it should be libdir?
I was wondering also whether it would make sense to have a libpgport.so?

It fixes various macros which are used by contrib makefiles, especially
libpq_*dir and LDFLAGS when used under PGXS. It seems to me that they are
needed to

It adds the ability to test and use PGXS with contribs, with make
USE_PGXS=1. Without the macro, this is exactly as before, there should be
no difference, esp. wrt the vpath feature that seemed broken by previous
submission. So it should not harm anybody, and it is useful at least to me.

It fixes some inconsistencies in various contrib makefiles
(useless override, := instead of =).

It works for me. it validates.

I'm available to fix any problem with this patch.

Have a nice day,

-- 
Fabien Coelho - [EMAIL PROTECTED]*** ./contrib/btree_gist/Makefile.orig  Fri May 28 15:09:43 2004
--- ./contrib/btree_gist/Makefile   Tue Aug 17 11:54:08 2004
***
*** 1,8 
  
- subdir = contrib/btree_gist
- top_builddir = ../..
- include $(top_builddir)/src/Makefile.global
- 
  MODULE_big  = btree_gist
  
  OBJS= btree_gist.o btree_utils_num.o btree_utils_var.o btree_int2.o 
btree_int4.o btree_int8.o \
--- 1,4 
***
*** 16,19 
--- 12,23 
  REGRESS = init int2 int4 int8 float4 float8 cash oid timestamp timestamptz time 
timetz \
date interval macaddr inet cidr text varchar char bytea bit varbit 
numeric
  
+ ifdef USE_PGXS
+ PGXS = $(shell pg_config --pgxs)
+ include $(PGXS)
+ else
+ subdir = contrib/btree_gist
+ top_builddir = ../..
+ include $(top_builddir)/src/Makefile.global
  include $(top_srcdir)/contrib/contrib-global.mk
+ endif
*** ./contrib/chkpass/Makefile.orig Sat Nov 29 20:51:19 2003
--- ./contrib/chkpass/Makefile  Tue Aug 17 11:54:08 2004
***
*** 1,13 
  # $PostgreSQL: pgsql-server/contrib/chkpass/Makefile,v 1.5 2003/11/29 19:51:19 pgsql 
Exp $
  
- subdir = contrib/chkpass
- top_builddir = ../..
- include $(top_builddir)/src/Makefile.global
- 
  MODULE_big = chkpass
  OBJS = chkpass.o
  SHLIB_LINK = $(filter -lcrypt, $(LIBS))
  DATA_built = chkpass.sql
  DOCS = README.chkpass
  
  include $(top_srcdir)/contrib/contrib-global.mk
--- 1,17 
  # $PostgreSQL: pgsql-server/contrib/chkpass/Makefile,v 1.5 2003/11/29 19:51:19 pgsql 
Exp $
  
  MODULE_big = chkpass
  OBJS = chkpass.o
  SHLIB_LINK = $(filter -lcrypt, $(LIBS))
  DATA_built = chkpass.sql
  DOCS = README.chkpass
  
+ ifdef USE_PGXS
+ PGXS = $(shell pg_config --pgxs)
+ include $(PGXS)
+ else
+ subdir = contrib/chkpass
+ top_builddir = ../..
+ include $(top_builddir)/src/Makefile.global
  include $(top_srcdir)/contrib/contrib-global.mk
+ endif
*** ./contrib/cube/Makefile.origSat Nov 29 20:51:21 2003
--- ./contrib/cube/Makefile Tue Aug 17 11:54:08 2004
***
*** 1,9 
  # $PostgreSQL: pgsql-server/contrib/cube/Makefile,v 1.11 2003/11/29 19:51:21 pgsql 
Exp $
  
- subdir = contrib/cube
- top_builddir = ../..
- include $(top_builddir)/src/Makefile.global
- 
  MODULE_big = cube
  OBJS= cube.o cubeparse.o
  
--- 1,5 
***
*** 11,16 
--- 7,25 
  DOCS = README.cube
  REGRESS = cube
  
+ EXTRA_CLEAN = cubeparse.c cubeparse.h cubescan.c y.tab.c y.tab.h
+ 
+ 
+ ifdef USE_PGXS
+ PGXS = $(shell pg_config --pgxs)
+ include $(PGXS)
+ else
+ subdir = contrib/cube
+ top_builddir = ../..
+ include $(top_builddir)/src/Makefile.global
+ include $(top_srcdir)/contrib/contrib-global.mk
+ endif
+ 
  
  # cubescan is compiled as part of cubeparse
  cubeparse.o: cubescan.c
***
*** 32,39 
  else
@$(missing) flex $ $@
  endif
- 
- EXTRA_CLEAN = cubeparse.c cubeparse.h cubescan.c y.tab.c y.tab.h
- 
- 
- include $(top_srcdir)/contrib/contrib-global.mk
--- 41,43 
*** ./contrib/dbase/Makefile.orig   Sat Nov 29 20:51:22 2003
--- ./contrib/dbase/MakefileTue Aug 17 11:54:08 2004
***
*** 1,9 
  # $PostgreSQL: pgsql-server/contrib/dbase/Makefile,v 1.5 2003/11/29 19:51:22 pgsql 
Exp $
  
- subdir = contrib/dbase
- top_builddir = ../..
- include $(top_builddir)/src/Makefile.global
- 
  PROGRAM = dbf2pg
  OBJS  = dbf.o dbf2pg.o endian.o
  PG_CPPFLAGS = -I$(libpq_srcdir)
--- 1,5 
***
*** 18,21 
--- 14,26 
  DOCS = README.dbf2pg
  MAN = dbf2pg.1# XXX not implemented
  
+ 
+ ifdef USE_PGXS
+ PGXS = $(shell pg_config --pgxs)
+ include $(PGXS)
+ else
+ subdir = contrib/dbase
+ top_builddir = ../..
+ include $(top_builddir)/src/Makefile.global
  include $(top_srcdir)/contrib/contrib-global.mk
+ endif
*** ./contrib/dblink/Makefile.orig  Sat Nov 29 20:51:34 2003
--- ./contrib/dblink/Makefile   Tue Aug 17 11:54:08 2004
***
*** 1,9 
  # $PostgreSQL: