diff options
author | mjl <mjl> | 2003-01-17 16:41:37 +0000 |
---|---|---|
committer | mjl <mjl> | 2003-01-17 16:41:37 +0000 |
commit | d14c6492221e68bdd33f0c11dd7597cd855a27a7 (patch) | |
tree | 3bc00fbc5efcf3b5bcf70342a0167a1790c67742 /databases | |
parent | ab6064d5be5fda43c13fb10a457aefe3e0e6986c (diff) | |
download | pkgsrc-d14c6492221e68bdd33f0c11dd7597cd855a27a7.tar.gz |
Update p5-DBD-postgresql to 1.21
- System tables no longer returned by tables().
- Fix table_attributes to handle removal of pg_relcheck in 7.3,
- Properly reset transaction status after failed transaction when
autocommit is off. Properly report transaction failure message.
- New pg_bool_tf database handle that when set to true booleans are
returned as 't'/'f' rather than 1/0.
- Maintenance transferred to GBorg.
- Added implementations of column_info() and table_info(), and
primary_key_info().
- The POD formatting was cleaned up.
- The preparser was updated to better handle escaped characters.
- Added eg/lotest.pl as a demonstration of using large objects in buffers
rather than files.
- Added LISTEN/NOTIFY functionality.
- Added constants for common PostgreSQL data types.
- Fixed compile-time warnings.
Diffstat (limited to 'databases')
-rw-r--r-- | databases/p5-DBD-postgresql/Makefile | 10 | ||||
-rw-r--r-- | databases/p5-DBD-postgresql/distinfo | 10 | ||||
-rw-r--r-- | databases/p5-DBD-postgresql/patches/patch-aa | 48 | ||||
-rw-r--r-- | databases/p5-DBD-postgresql/patches/patch-ab | 13 |
4 files changed, 43 insertions, 38 deletions
diff --git a/databases/p5-DBD-postgresql/Makefile b/databases/p5-DBD-postgresql/Makefile index 0b951502232..5fede39e25b 100644 --- a/databases/p5-DBD-postgresql/Makefile +++ b/databases/p5-DBD-postgresql/Makefile @@ -1,16 +1,16 @@ -# $NetBSD: Makefile,v 1.21 2003/01/05 20:14:24 jlam Exp $ +# $NetBSD: Makefile,v 1.22 2003/01/17 16:41:37 mjl Exp $ # -VER= 1.13 +VER= 1.21 DISTNAME= DBD-Pg-${VER} PKGNAME= p5-DBD-postgresql-${VER} -PKGREVISION= 3 +# PKGREVISION= 3 SVR4_PKGNAME= p5dpo CATEGORIES= databases perl5 -MASTER_SITES= ${MASTER_SITE_PERL_CPAN:=../../authors/id/JBAKER/} +MASTER_SITES= ${MASTER_SITE_PERL_CPAN:=DBD/} MAINTAINER= jwise@netbsd.org -HOMEPAGE= http://www.postgresql.org/ +HOMEPAGE= http://gborg.postgresql.org/project/dbdpg/projdisplay.php COMMENT= perl DBI/DBD driver for PostgreSQL databases USE_BUILDLINK2= YES diff --git a/databases/p5-DBD-postgresql/distinfo b/databases/p5-DBD-postgresql/distinfo index 51352d80a08..0ff8ccf04fd 100644 --- a/databases/p5-DBD-postgresql/distinfo +++ b/databases/p5-DBD-postgresql/distinfo @@ -1,6 +1,6 @@ -$NetBSD: distinfo,v 1.12 2002/08/21 23:10:38 mjl Exp $ +$NetBSD: distinfo,v 1.13 2003/01/17 16:41:38 mjl Exp $ -SHA1 (DBD-Pg-1.13.tar.gz) = f99a5aeebd71e0cac273311cb3405d9ed5e3e9c2 -Size (DBD-Pg-1.13.tar.gz) = 43038 bytes -SHA1 (patch-aa) = bd394a9052e532c6deb59c0531ed34b0f4f98e3e -SHA1 (patch-ab) = 5b8ee2423026727afdf87a482f681003d491ec39 +SHA1 (DBD-Pg-1.21.tar.gz) = d52b6005fc6e7de1c5f8274e3c80e5375e94c413 +Size (DBD-Pg-1.21.tar.gz) = 77446 bytes +SHA1 (patch-aa) = c1e39f684ea515d09801a714ab4ba06c01b13f6f +SHA1 (patch-ab) = 628bbc7bf3b4862b4c53ba4843dcc7161bff1ead diff --git a/databases/p5-DBD-postgresql/patches/patch-aa b/databases/p5-DBD-postgresql/patches/patch-aa index 2c8907c797b..b1505de168c 100644 --- a/databases/p5-DBD-postgresql/patches/patch-aa +++ b/databases/p5-DBD-postgresql/patches/patch-aa @@ -1,7 +1,7 @@ -$NetBSD: patch-aa,v 1.2 2002/08/21 23:10:39 mjl Exp $ +$NetBSD: patch-aa,v 1.3 2003/01/17 16:41:39 mjl Exp $ ---- dbdimp.c.orig Sat Apr 27 22:35:52 2002 -+++ dbdimp.c Thu Aug 22 01:01:06 2002 +--- dbdimp.c.orig Wed Jan 8 23:08:17 2003 ++++ dbdimp.c Fri Jan 17 17:23:37 2003 @@ -40,6 +40,30 @@ @@ -33,43 +33,49 @@ $NetBSD: patch-aa,v 1.2 2002/08/21 23:10:39 mjl Exp $ dbd_discon_all (drh, imp_drh) SV *drh; imp_drh_t *imp_drh; -@@ -191,6 +215,7 @@ - +@@ -192,6 +216,7 @@ imp_dbh->init_commit = 1; /* initialize AutoCommit */ imp_dbh->pg_auto_escape = 1; /* initialize pg_auto_escape */ + imp_dbh->pg_bool_tf = 0; /* initialize pg_bool_tf */ + imp_dbh->need_begin = 1; DBIc_IMPSET_on(imp_dbh); /* imp_dbh set up now */ DBIc_ACTIVE_on(imp_dbh); /* call disconnect before freeing */ -@@ -241,6 +266,9 @@ +@@ -283,6 +308,9 @@ PGresult* result = 0; - ExecStatusType status; + ExecStatusType commitstatus, beginstatus; -+ if (imp_dbh->need_begin) -+ return 1; ++ if (imp_dbh->need_begin) ++ return 1; + /* execute commit */ result = PQexec(imp_dbh->conn, "commit"); - status = result ? PQresultStatus(result) : -1; -@@ -252,15 +280,8 @@ - return 0; + commitstatus = result ? PQresultStatus(result) : -1; +@@ -294,21 +322,12 @@ + pg_error(dbh, commitstatus, PQerrorMessage(imp_dbh->conn)); } - /* start new transaction. AutoCommit must be FALSE, ref. 20 lines up */ - result = PQexec(imp_dbh->conn, "begin"); -- status = result ? PQresultStatus(result) : -1; +- beginstatus = result ? PQresultStatus(result) : -1; - PQclear(result); -- if (status != PGRES_COMMAND_OK) { -- pg_error(dbh, status, "begin failed\n"); +- if (beginstatus != PGRES_COMMAND_OK) { +- /* Maybe add some loud barf here? Raising some very high error? */ +- pg_error(dbh, beginstatus, "begin failed\n"); - return 0; - } +- + /* if the initial COMMIT failed, return 0 now */ + if (commitstatus != PGRES_COMMAND_OK) { + return 0; + } - -+ imp_dbh->need_begin = 1; + ++ imp_dbh->need_begin = 1; return 1; } -@@ -284,6 +305,9 @@ +@@ -332,6 +351,9 @@ PGresult* result = 0; ExecStatusType status; @@ -79,7 +85,7 @@ $NetBSD: patch-aa,v 1.2 2002/08/21 23:10:39 mjl Exp $ /* execute rollback */ result = PQexec(imp_dbh->conn, "rollback"); status = result ? PQresultStatus(result) : -1; -@@ -295,15 +319,8 @@ +@@ -343,15 +365,8 @@ return 0; } @@ -97,7 +103,7 @@ $NetBSD: patch-aa,v 1.2 2002/08/21 23:10:39 mjl Exp $ return 1; } -@@ -326,7 +343,8 @@ +@@ -374,7 +389,8 @@ if (NULL != imp_dbh->conn) { /* rollback if AutoCommit = off */ @@ -107,7 +113,7 @@ $NetBSD: patch-aa,v 1.2 2002/08/21 23:10:39 mjl Exp $ PGresult* result = 0; ExecStatusType status; result = PQexec(imp_dbh->conn, "rollback"); -@@ -402,16 +420,7 @@ +@@ -450,16 +466,7 @@ if (dbis->debug >= 2) { PerlIO_printf(DBILOGFP, "dbd_db_STORE: switch AutoCommit to on: commit\n"); } } else if ((oldval != FALSE && newval == FALSE) || (oldval == FALSE && newval == FALSE && imp_dbh->init_commit)) { if (NULL != imp_dbh->conn) { @@ -125,7 +131,7 @@ $NetBSD: patch-aa,v 1.2 2002/08/21 23:10:39 mjl Exp $ } if (dbis->debug >= 2) { PerlIO_printf(DBILOGFP, "dbd_db_STORE: switch AutoCommit to off: begin\n"); } } -@@ -1080,6 +1089,11 @@ +@@ -1142,6 +1149,11 @@ return -2; } diff --git a/databases/p5-DBD-postgresql/patches/patch-ab b/databases/p5-DBD-postgresql/patches/patch-ab index c7e8c1f1986..487b01adc99 100644 --- a/databases/p5-DBD-postgresql/patches/patch-ab +++ b/databases/p5-DBD-postgresql/patches/patch-ab @@ -1,13 +1,12 @@ -$NetBSD: patch-ab,v 1.1 2002/06/18 07:05:32 explorer Exp $ +$NetBSD: patch-ab,v 1.2 2003/01/17 16:41:39 mjl Exp $ -diff -ur dbdimp.h.orig dbdimp.h ---- dbdimp.h.orig Thu Apr 4 18:55:51 2002 -+++ dbdimp.h Thu Apr 4 19:08:29 2002 -@@ -22,6 +22,7 @@ - PGconn * conn; /* connection structure */ +--- dbdimp.h.orig Wed Jan 8 23:08:17 2003 ++++ dbdimp.h Fri Jan 17 17:25:12 2003 +@@ -23,6 +23,7 @@ int init_commit; /* initialize AutoCommit */ int pg_auto_escape; /* initialize AutoEscape */ -+ int need_begin; /* need a begin */ + int pg_bool_tf; /* do bools return 't'/'f' */ ++ int need_begin; /* need a begin */ }; /* Define sth implementor data structure */ |