r21041 - in /trunk/libdbd-pg-perl: Changes META.yml Makefile.PL Pg.pm README SIGNATURE debian/changelog lib/Bundle/DBD/Pg.pm t/01connect.t t/02attribs.t t/12placeholders.t t/99cleanup.t t/dbdpg_test_setup.pl

gregoa at users.alioth.debian.org gregoa at users.alioth.debian.org
Sat Jun 14 19:02:38 UTC 2008


Author: gregoa
Date: Sat Jun 14 19:02:38 2008
New Revision: 21041

URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=21041
Log:
New upstream release.

Modified:
    trunk/libdbd-pg-perl/Changes
    trunk/libdbd-pg-perl/META.yml
    trunk/libdbd-pg-perl/Makefile.PL
    trunk/libdbd-pg-perl/Pg.pm
    trunk/libdbd-pg-perl/README
    trunk/libdbd-pg-perl/SIGNATURE
    trunk/libdbd-pg-perl/debian/changelog
    trunk/libdbd-pg-perl/lib/Bundle/DBD/Pg.pm
    trunk/libdbd-pg-perl/t/01connect.t
    trunk/libdbd-pg-perl/t/02attribs.t
    trunk/libdbd-pg-perl/t/12placeholders.t
    trunk/libdbd-pg-perl/t/99cleanup.t
    trunk/libdbd-pg-perl/t/dbdpg_test_setup.pl

Modified: trunk/libdbd-pg-perl/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdbd-pg-perl/Changes?rev=21041&op=diff
==============================================================================
--- trunk/libdbd-pg-perl/Changes (original)
+++ trunk/libdbd-pg-perl/Changes Sat Jun 14 19:02:38 2008
@@ -1,6 +1,12 @@
 ('GSM' is Greg Sabino Mullane, greg at turnstep.com)
 
-2.8.0 Released June 1, 2008
+2.8.1 Released June 11, 2008
+
+	- Force testing to use a custom socket dir, to avoid 
+		permission problems. Thanks to Frank Wiegand for 
+		help in uncovering this. [GSM]
+
+2.8.0 Released June 1, 2008 (subversion r11366)
 
 	- Added in payload strings for LISTEN/NOTIFY in 8.4 
 		via $dbh->pg_notifies() [GSM]

Modified: trunk/libdbd-pg-perl/META.yml
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdbd-pg-perl/META.yml?rev=21041&op=diff
==============================================================================
--- trunk/libdbd-pg-perl/META.yml (original)
+++ trunk/libdbd-pg-perl/META.yml Sat Jun 14 19:02:38 2008
@@ -1,43 +1,47 @@
 --- #YAML:1.0
-name                  : DBD-Pg
-version               : 2.8.0
-abstract              : DBI PostgreSQL interface
+name                        : DBD-Pg
+version                     : 2.8.1
+abstract                    : DBI PostgreSQL interface
 author:              
   - Greg Sabino Mullane <greg at turnstep.com>
 
-license               : perl
-distribution_type     : module
-dynamic_config        : 1
+license                     : perl
+distribution_type           : module
+dynamic_config              : 1
 
 requires:
-  DBI                 : 1.52
-  perl                : 5.006001
-  version             : 0
+  DBI                       : 1.52
+  perl                      : 5.006001
+  version                   : 0
 recommends:
-  Encode              : 0
-  File::Temp          : 0
-  Module::Signature   : 0.50
-  Perl::Critic        : 0
-  Time::HiRes         : 0
-  Test::Pod           : 0.95
-  Test::Pod::Coverage : 0
-  Test::Warn          : 0.08
-  Test::YAML::Meta    : 0.03
+  Cwd                       : 0
+  Encode                    : 0
+  File::Temp                : 0
+  File::Comments::Plugin::C : 0
+  Module::Signature         : 0.50
+  Perl::Critic              : 0
+  Pod::Spell                : 0
+  Time::HiRes               : 0
+  Test::Pod                 : 0.95
+  Test::Pod::Coverage       : 0
+  Test::Warn                : 0.08
+  Test::YAML::Meta          : 0.03
+  Text::Spellchecker        : 0
 build_requires:
-  DBI                 : 1.52
-  Test::More          : 0.61
-  version             : 0
+  DBI                       : 1.52
+  Test::More                : 0.61
+  version                   : 0
 configure_requires:
-  DBI                 : 1.52
-  version             : 0
+  DBI                       : 1.52
+  version                   : 0
 
 provides:
   DBD::Pg:
-    file              : Pg.pm
-    version           : 2.8.0
+    file                    : Pg.pm
+    version                 : 2.8.1
   Bundle::DBD::Pg:
-    file              : lib/Bundle/DBD/Pg.pm
-    version           : 2.8.0
+    file                    : lib/Bundle/DBD/Pg.pm
+    version                 : 2.8.1
 
 keywords:
   - Postgres
@@ -46,14 +50,14 @@
   - libpq
 
 resources:
-  homepage            : http://search.cpan.org/dist/DBD-Pg/
-  license             : http://dev.perl.org/licenses/
-  bugtracker          : http://rt.cpan.org/Public/Dist/Display.html?Name=DBD-Pg
-  MailingList         : http://www.nntp.perl.org/group/perl.dbd.pg/
-  Repository          : http://svn.perl.org/modules/DBD-Pg/trunk/
+  homepage                  : http://search.cpan.org/dist/DBD-Pg/
+  license                   : http://dev.perl.org/licenses/
+  bugtracker                : http://rt.cpan.org/Public/Dist/Display.html?Name=DBD-Pg
+  MailingList               : http://www.nntp.perl.org/group/perl.dbd.pg/
+  Repository                : http://svn.perl.org/modules/DBD-Pg/trunk/
 
 meta-spec:
-  version             : 1.3
-  url                 : http://module-build.sourceforge.net/META-spec-v1.3.html
+  version                   : 1.3
+  url                       : http://module-build.sourceforge.net/META-spec-v1.3.html
 
-generated_by          : emacs
+generated_by                : emacs

Modified: trunk/libdbd-pg-perl/Makefile.PL
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdbd-pg-perl/Makefile.PL?rev=21041&op=diff
==============================================================================
--- trunk/libdbd-pg-perl/Makefile.PL (original)
+++ trunk/libdbd-pg-perl/Makefile.PL Sat Jun 14 19:02:38 2008
@@ -1,4 +1,4 @@
-# $Id: Makefile.PL 11360 2008-06-01 20:12:07Z turnstep $
+# $Id: Makefile.PL 11400 2008-06-10 17:42:07Z turnstep $
 
 use ExtUtils::MakeMaker;
 use Config;
@@ -7,7 +7,7 @@
 use 5.006001;
 
 ## No version.pm for this one, as the prereqs are not loaded yet.
-my $VERSION = '2.8.0';
+my $VERSION = '2.8.1';
 
 my $lib;
 BEGIN {

Modified: trunk/libdbd-pg-perl/Pg.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdbd-pg-perl/Pg.pm?rev=21041&op=diff
==============================================================================
--- trunk/libdbd-pg-perl/Pg.pm (original)
+++ trunk/libdbd-pg-perl/Pg.pm Sat Jun 14 19:02:38 2008
@@ -1,5 +1,5 @@
 #  -*-cperl-*-
-#  $Id: Pg.pm 11364 2008-06-02 01:20:45Z turnstep $
+#  $Id: Pg.pm 11412 2008-06-11 23:12:10Z turnstep $
 #
 #  Copyright (c) 2002-2008 Greg Sabino Mullane and others: see the Changes file
 #  Portions Copyright (c) 2002 Jeffrey W. Baker
@@ -17,7 +17,7 @@
 {
 	package DBD::Pg;
 
-	use version; our $VERSION = qv('2.8.0');
+	use version; our $VERSION = qv('2.8.1');
 
 	use DBI ();
 	use DynaLoader ();
@@ -1688,7 +1688,7 @@
 
 =head1 VERSION
 
-This documents version 2.8.0 of the DBD::Pg module
+This documents version 2.8.1 of the DBD::Pg module
 
 =head1 DESCRIPTION
 
@@ -2976,7 +2976,8 @@
 =item B<pg_standard_conforming_strings> (boolean, read-only)
 
 DBD::Pg specific attribute.  Returns if the server is currently using 
-standard conforming strings or not.
+standard conforming strings or not. Only available if the target 
+server is version 8.2 or better.
 
 =item B<pg_async_status> (integer, read-only)
 

Modified: trunk/libdbd-pg-perl/README
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdbd-pg-perl/README?rev=21041&op=diff
==============================================================================
--- trunk/libdbd-pg-perl/README (original)
+++ trunk/libdbd-pg-perl/README Sat Jun 14 19:02:38 2008
@@ -1,12 +1,12 @@
 
 DBD::Pg  --  the DBI PostgreSQL interface for Perl
 
-# $Id: README 11317 2008-05-25 17:12:54Z turnstep $
+# $Id: README 11400 2008-06-10 17:42:07Z turnstep $
 
 DESCRIPTION:
 ------------
 
-This is version 2.8.0 of DBD::Pg.  The web site for this interface, and 
+This is version 2.8.1 of DBD::Pg.  The web site for this interface, and 
 the latest version, can be found at:
 
 	http://search.cpan.org/dist/DBD-Pg/

Modified: trunk/libdbd-pg-perl/SIGNATURE
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdbd-pg-perl/SIGNATURE?rev=21041&op=diff
==============================================================================
--- trunk/libdbd-pg-perl/SIGNATURE (original)
+++ trunk/libdbd-pg-perl/SIGNATURE Sat Jun 14 19:02:38 2008
@@ -15,29 +15,29 @@
 Hash: RIPEMD160
 
 SHA1 f0ec5e26a58bb8848c779560f654d7ff6444bd62 .perlcriticrc
-SHA1 6cd8dd00162b4b739c4297b12bd4d6dd507de5be Changes
+SHA1 64fdf9ef4491ea25f76ce7af5eb41b717b7d1695 Changes
 SHA1 4d91c71e5dbb19ece1505ab75c36d00a744bb076 MANIFEST
 SHA1 22055b195f5cf15d7909e8a08468e617f46154e7 MANIFEST.SKIP
-SHA1 242d46141b889c02114bbcfa63ec81072fcac488 META.yml
-SHA1 c9370b7e98584276f13329c1114b0fa4c0cf25ab Makefile.PL
+SHA1 2d0c181af631b4c1f99b22b315b9549abb36bb84 META.yml
+SHA1 91a97af58dd0b6afccb93df1eb8483240f121ce7 Makefile.PL
 SHA1 c51356c52c139265e20a2ad33bc8d3ee04f6ff48 Pg.h
-SHA1 77da8db1a165562a50270d68bee67b69279d3ac8 Pg.pm
+SHA1 775fd7b719d3979bb41b114b1190816f31820295 Pg.pm
 SHA1 06d991c871e5f2b3b900990fc71e6207c94ad8cf Pg.xs
-SHA1 7d36f9b1de97e830d6275e2c24c234f52395a1b4 README
+SHA1 3f2acadc8215a795d9700566149ac568884863a5 README
 SHA1 283327a19b823faa386bcc85d5104baca40aaa35 README.dev
 SHA1 968d5fad61bce160b31a9cb1a21dd240b9df930f README.win32
 SHA1 3cc0dc67acbb3c3a34f95bb6c9f308b165898d06 TODO
 SHA1 2ee3930895ededd7253a3f9ce3bd9f6ed5bdc224 dbdimp.c
 SHA1 9a5244ebe27af6f18c5dc8713fe8aecaa334134e dbdimp.h
 SHA1 6c33bcf138e577722283bef02fceb8cbce4d100d dbivport.h
-SHA1 361ca5b49231b996ac1946db9459e496c5dfb337 lib/Bundle/DBD/Pg.pm
+SHA1 35a8bc405e0257c6c6e1c42e67e1cd8bad2fba41 lib/Bundle/DBD/Pg.pm
 SHA1 76a2c65c065a93775ceadf933a5d38bb25c8afa4 quote.c
 SHA1 0a1fdd0406c5c367a9aba366d1d35cfa8d5272ae quote.h
 SHA1 4da4f8074e8f46d4e787906fa6de3ebbadef29ed t/00-signature.t
 SHA1 5af8ab01ab090be9daf556c5b03def8bacb3b8cd t/00basic.t
-SHA1 161f28352c0dbc8e8e22a4344ea874719d713f99 t/01connect.t
+SHA1 120ad9a523d8cb7affab6d38f5d44a2ffce7e6a7 t/01connect.t
 SHA1 655b72fa5f29886caa9b4a0ac7d69dc078d4bf55 t/01constants.t
-SHA1 3cbdc0ebf77db68bb7e0a54bd563c7c893882fa5 t/02attribs.t
+SHA1 797ce6c8b6bb49800f33d3792165eb8c84bb370d t/02attribs.t
 SHA1 914ba6cc8161552f03ad1d507cff5e1b90f4cfb2 t/03dbmethod.t
 SHA1 267c1961ea9cce5ad491b95e01e465b9a6746dd3 t/03smethod.t
 SHA1 d04c4a1d73d8c73fd2e137b4cf3dfc8db8afa120 t/04misc.t
@@ -45,14 +45,14 @@
 SHA1 1002b952950258a004a5485e8acd6032d38533b7 t/07copy.t
 SHA1 5ee1eabc257b4ca68dc057b526514def24740383 t/08async.t
 SHA1 98bbf45b2e2e5f299b0859fb08623ffa10bfc3d0 t/09arrays.t
-SHA1 e1ee17778109fb43cd60328844b184b2bdcfc263 t/12placeholders.t
+SHA1 b1be0cffd8ea9e9a1c560d9d67840eaa67a2d402 t/12placeholders.t
 SHA1 6bdf8e55f3ea98f33af91e8f6af628901e66cd34 t/20savepoints.t
 SHA1 addf7fcdcf836fac6b97a9bcadd3daaf2854ae11 t/99_perlcritic.t
 SHA1 74f4e54a0e8e9e8501ef1c13c05efb757d271bd4 t/99_pod.t
 SHA1 f66b5581261c89bb58a6a4d26e76336a432802cd t/99_spellcheck.t
 SHA1 e9e984b3c3366d5cee873f1dc59e2b7c26e744ee t/99_yaml.t
-SHA1 3d504299158dadf6a4e187680109a14dbd1bc6ad t/99cleanup.t
-SHA1 f5df45a00fb2c7580eb5130796b496a6ea20feb8 t/dbdpg_test_setup.pl
+SHA1 5b82b5443966e3ae98fcdb8668059a8969058cf0 t/99cleanup.t
+SHA1 023f0e7423ec75fba162e34fd148776cacacb6a9 t/dbdpg_test_setup.pl
 SHA1 bc4a58bdd5e853139f9e1fc6129f83e50a07a2c6 t/lib/App/Info.pm
 SHA1 58befda00c12b1721875262505112203bf230450 t/lib/App/Info/Handler.pm
 SHA1 b5bf85b12a5fc207c44113a9c028fb7fbd68531f t/lib/App/Info/Handler/Prompt.pm
@@ -65,7 +65,7 @@
 SHA1 f07cd5ecaeb854c81ceb9206364979cf607e6546 win32.mak
 -----BEGIN PGP SIGNATURE-----
 
-iEYEAREDAAYFAkhDTPMACgkQvJuQZxSWSshaqACg4F6hrmmXnZOw8fd8rU1BuOp2
-yQcAn3w5ZML2x6WzO4fP2G01If3WMEVC
-=Kebv
+iEYEAREDAAYFAkhQjl4ACgkQvJuQZxSWSshtEQCfYofmrq5NQxkYweMTntuTtKwK
+Vr0AnR3MVG+LflnclzzodMDeNvF/cDXM
+=3Bx5
 -----END PGP SIGNATURE-----

Modified: trunk/libdbd-pg-perl/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdbd-pg-perl/debian/changelog?rev=21041&op=diff
==============================================================================
--- trunk/libdbd-pg-perl/debian/changelog (original)
+++ trunk/libdbd-pg-perl/debian/changelog Sat Jun 14 19:02:38 2008
@@ -1,6 +1,10 @@
-libdbd-pg-perl (2.8.0-2) UNRELEASED; urgency=low
-
+libdbd-pg-perl (2.8.1-1) UNRELEASED; urgency=low
+
+  [ Martín Ferrari ]
   * Updating my email address
+
+  [ gregor herrmann ]
+  * New upstream release.
 
  -- Martín Ferrari <tincho at debian.org>  Fri, 13 Jun 2008 00:04:40 +0000
 

Modified: trunk/libdbd-pg-perl/lib/Bundle/DBD/Pg.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdbd-pg-perl/lib/Bundle/DBD/Pg.pm?rev=21041&op=diff
==============================================================================
--- trunk/libdbd-pg-perl/lib/Bundle/DBD/Pg.pm (original)
+++ trunk/libdbd-pg-perl/lib/Bundle/DBD/Pg.pm Sat Jun 14 19:02:38 2008
@@ -4,7 +4,7 @@
 use strict;
 use warnings;
 
-$VERSION = '2.8.0';
+$VERSION = '2.8.1';
 
 1;
 

Modified: trunk/libdbd-pg-perl/t/01connect.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdbd-pg-perl/t/01connect.t?rev=21041&op=diff
==============================================================================
--- trunk/libdbd-pg-perl/t/01connect.t (original)
+++ trunk/libdbd-pg-perl/t/01connect.t Sat Jun 14 19:02:38 2008
@@ -98,6 +98,10 @@
 	my $pv = sprintf('%vd', $^V);
 	my $schema = 'dbd_pg_testschema';
 	my $dsn = exists $ENV{DBI_DSN} ? $ENV{DBI_DSN} : '?';
+
+	## Don't show current dir to the world via CPAN::Reporter results
+	$dsn =~ s{host=/.*(dbdpg_test_database/data/socket)}{host=<pwd>/$1};
+
 	my $ver = defined $DBD::Pg::VERSION ? $DBD::Pg::VERSION : '?';
 	my $user = exists $ENV{DBI_USER} ? $ENV{DBI_USER} : '<not set>';
 	my $offset = 27;

Modified: trunk/libdbd-pg-perl/t/02attribs.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdbd-pg-perl/t/02attribs.t?rev=21041&op=diff
==============================================================================
--- trunk/libdbd-pg-perl/t/02attribs.t (original)
+++ trunk/libdbd-pg-perl/t/02attribs.t Sat Jun 14 19:02:38 2008
@@ -324,8 +324,8 @@
 
 SKIP: {
 
-	if ($pgversion < 80100) {
-		skip 'Cannot test standard_conforming_strings on pre 8.1 servers', 3;
+	if ($pgversion < 80200) {
+		skip 'Cannot test standard_conforming_strings on pre 8.2 servers', 3;
 	}
 
 	$t=q{DB handle attribute "pg_standard_conforming_strings" returns a valid value};

Modified: trunk/libdbd-pg-perl/t/12placeholders.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdbd-pg-perl/t/12placeholders.t?rev=21041&op=diff
==============================================================================
--- trunk/libdbd-pg-perl/t/12placeholders.t (original)
+++ trunk/libdbd-pg-perl/t/12placeholders.t Sat Jun 14 19:02:38 2008
@@ -131,8 +131,9 @@
 	$dbh->do(q{SET NAMES 'UTF8'});
 }
 
-my $SQL = 'SHOW backslash_quote';
-my $backslash = $dbh->selectall_arrayref($SQL)->[0][0];
+my $SQL = q{SELECT setting FROM pg_settings WHERE name = 'backslash_quote'};
+$count = $dbh->selectall_arrayref($SQL)->[0];
+my $backslash = defined $count ? $count->[0] : 0;
 
 $t=q{Prepare with backslashes inside quotes works};
 my $scs = $dbh->{pg_standard_conforming_strings};

Modified: trunk/libdbd-pg-perl/t/99cleanup.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdbd-pg-perl/t/99cleanup.t?rev=21041&op=diff
==============================================================================
--- trunk/libdbd-pg-perl/t/99cleanup.t (original)
+++ trunk/libdbd-pg-perl/t/99cleanup.t Sat Jun 14 19:02:38 2008
@@ -22,7 +22,6 @@
 	cleanup_database($dbh);
 }
 
-shutdown_test_database();
-
 $dbh->disconnect() if defined $dbh and ref $dbh;
 
+shutdown_test_database();

Modified: trunk/libdbd-pg-perl/t/dbdpg_test_setup.pl
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdbd-pg-perl/t/dbdpg_test_setup.pl?rev=21041&op=diff
==============================================================================
--- trunk/libdbd-pg-perl/t/dbdpg_test_setup.pl (original)
+++ trunk/libdbd-pg-perl/t/dbdpg_test_setup.pl Sat Jun 14 19:02:38 2008
@@ -5,6 +5,7 @@
 use warnings;
 use Data::Dumper;
 use DBI;
+use Cwd;
 select(($|=1,select(STDERR),$|=1)[1]);
 
 my @schemas =
@@ -65,6 +66,9 @@
 	## First, check to see if we've been here before and left directions
 	my ($testdsn,$testuser,$helpconnect,$su,$testdir,$pg_ctl) = get_test_settings();
 
+	## For debugging purposes, we'll be storing this in README.testdatabase as well
+	my $initdb = 'default';
+
 	## Did we fail last time? Fail this time too, but quicker!
 	if ($testdsn =~ /FAIL!/) {
 		return $helpconnect, 'Previous failure', undef;
@@ -100,20 +104,32 @@
 				warn "Test directory $testdir has been removed, will recreate from scratch\n";
 			}
 			else {
-				warn "Restarting test database $testdsn at $testdir\n";
-
-				my $COM = qq{$pg_ctl -l $testdir/dbdpg_test.logfile -D $testdir start};
-				if ($su) {
-					$COM = qq{su -m $su -c "$COM"};
+				if (-e "$test_database_dir/data/postmaster.pid") {
+					## Assume it's up, and move on
 				}
-				$info = '';
-				eval { $info = qx{$COM}; };
-				if ($@ or $info !~ /\w/) {
-					$@ = "Could not startup new database ($@) ($info)";
-					return $helpconnect, $@, undef;
+				else {
+
+					warn "Restarting test database $testdsn at $testdir\n";
+					my $option = '';
+					if ($^O !~ /Win32/) {
+						if (! -e "$test_database_dir/data/socket") {
+							mkdir "$test_database_dir/data/socket";
+						}
+						$option = q{-o '-k socket'};
+					}
+					my $COM = qq{$pg_ctl $option -l $testdir/dbdpg_test.logfile -D $testdir start};
+					if ($su) {
+						$COM = qq{su -m $su -c "$COM"};
+					}
+					$info = '';
+					eval { $info = qx{$COM}; };
+					if ($@ or $info !~ /\w/) {
+						$@ = "Could not startup new database ($@) ($info)";
+						return $helpconnect, $@, undef;
+					}
+					## Wait for it to startup and verify the connection
+					sleep 1;
 				}
-				## Wait for it to startup and verify the connection
-				sleep 1;
 				my $loop = 1;
 			  STARTUP: {
 					eval {
@@ -201,7 +217,7 @@
 		$helpconnect = 16;
 
 		## Use the initdb found by App::Info
-		my $initdb = $ENV{PGINITDB} || '';
+		$initdb = $ENV{PGINITDB} || '';
 		if (!$initdb or ! -e $initdb) {
 			$initdb = 'initdb';
 		}
@@ -255,7 +271,7 @@
 			## Start with whoever owns this file, unless it's us
 			my @userlist = (qw/postgres postgresql pgsql/);
 			my $username = getpwuid ((stat($0))[4]);
-			unshift @userlist, $username if $username ne getpwent;
+			unshift @userlist, $username if defined $username and $username ne getpwent;
 			my %doneuser;
 			for my $user (@userlist) {
 				next if $doneuser{$user}++;
@@ -335,7 +351,7 @@
 			$@ = qq{Could not open "$conf": $!};
 			last GETHANDLE;
 		}
-		print $cfh "\n\n## DBD::Pg testing parameters\nport=$testport\nmax_connections=3\n";
+		print $cfh "\n\n## DBD::Pg testing parameters\nport=$testport\nmax_connections=4\n";
 		print $cfh "listen_addresses='localhost'\n" if $^O =~ /Win32/;
 		print $cfh "\n";
 		close $cfh or die qq{Could not close "$conf": $!\n};
@@ -346,7 +362,14 @@
 		}
 		else {
 			$info = '';
-			my $COM = qq{$pg_ctl -l $test_database_dir/data/dbdpg_test.logfile -D $test_database_dir/data start};
+			my $option = '';
+			if ($^O !~ /Win32/) {
+				if (! -e "$test_database_dir/data/socket") {
+					mkdir "$test_database_dir/data/socket";
+				}
+				$option = q{-o '-k socket'};
+			}
+			my $COM = qq{$pg_ctl $option -l $test_database_dir/dbdpg_test.logfile -D $test_database_dir/data start};
 			if ($su) {
 				$COM = qq{su -m $su -c "$COM"};
 			}
@@ -364,6 +387,11 @@
 		$testdsn = "dbi:Pg:dbname=postgres;port=$testport";
 		if ($^O =~ /Win32/) {
 			$testdsn .= ';host=localhost';
+		}
+		else {
+			my $dir = getcwd;
+			my $socketdir = "$dir/$test_database_dir/data/socket";
+			$testdsn .= ";host=$socketdir";
 		}
 		my $loop = 1;
 	  STARTUP: {
@@ -391,6 +419,7 @@
 		print $fh "## Feel free to remove it!\n";
 		print $fh "## Helpconnect: $helpconnect\n";
 		print $fh "## pg_ctl: $pg_ctl\n";
+		print $fh "## initdb: $initdb\n";
 		if ($@) {
 			print $fh "## DSN: FAIL!\n";
 			print $fh "## ERROR: $@\n";




More information about the Pkg-perl-cvs-commits mailing list