public inbox for [email protected]  
help / color / mirror / Atom feed
Re: pg_upgrade should truncate/remove its logs before running
8+ messages / 4 participants
[nested] [flat]

* Re: pg_upgrade should truncate/remove its logs before running
@ 2022-02-06 07:17  Tom Lane <[email protected]>
  0 siblings, 1 reply; 8+ messages in thread

From: Tom Lane @ 2022-02-06 07:17 UTC (permalink / raw)
  To: Michael Paquier <[email protected]>; +Cc: Andrew Dunstan <[email protected]>; Justin Pryzby <[email protected]>; Peter Eisentraut <[email protected]>; Daniel Gustafsson <[email protected]>; Bruce Momjian <[email protected]>; [email protected]

Michael Paquier <[email protected]> writes:
> On Sun, Feb 06, 2022 at 01:58:21AM -0500, Tom Lane wrote:
>> As already mentioned, there's been no notice to buildfarm owners ...
>> so has Andrew actually made a release?

> There has been one as of 8 days ago:
> https://github.com/PGBuildFarm/client-code/releases

[ scrapes buildfarm logs ... ]

Not even Andrew's own buildfarm critters are using it, so
permit me leave to doubt that he thinks it's fully baked.

Andrew?

			regards, tom lane






^ permalink  raw  reply  [nested|flat] 8+ messages in thread

* Re: pg_upgrade should truncate/remove its logs before running
@ 2022-02-06 13:32  Andrew Dunstan <[email protected]>
  parent: Tom Lane <[email protected]>
  0 siblings, 0 replies; 8+ messages in thread

From: Andrew Dunstan @ 2022-02-06 13:32 UTC (permalink / raw)
  To: Tom Lane <[email protected]>; Michael Paquier <[email protected]>; +Cc: Justin Pryzby <[email protected]>; Peter Eisentraut <[email protected]>; Daniel Gustafsson <[email protected]>; Bruce Momjian <[email protected]>; [email protected]


On 2/6/22 02:17, Tom Lane wrote:
> Michael Paquier <[email protected]> writes:
>> On Sun, Feb 06, 2022 at 01:58:21AM -0500, Tom Lane wrote:
>>> As already mentioned, there's been no notice to buildfarm owners ...
>>> so has Andrew actually made a release?
>> There has been one as of 8 days ago:
>> https://github.com/PGBuildFarm/client-code/releases
> [ scrapes buildfarm logs ... ]
>
> Not even Andrew's own buildfarm critters are using it, so
> permit me leave to doubt that he thinks it's fully baked.
>
> Andrew?
>
> 			


*sigh* Sometimes I have a mind like a sieve. I prepped the release a few
days ago and meant to come back the next morning and send out emails
announcing it, as well as rolling it out to my animals, and got diverted
so that didn't happen and it slipped my mind. I'll go and do those
things now.

But the commit really shouldn't have happened until we know that most
buildfarm owners have installed it. It should have waited wait not just
for the release but for widespread deployment. Otherwise we will just
lose any logging for an error that might appear.


cheers


andrew


--
Andrew Dunstan
EDB: https://www.enterprisedb.com







^ permalink  raw  reply  [nested|flat] 8+ messages in thread

* [PATCH 13/19] another way to install uri-regress/uri_regress
@ 2022-05-27 03:24  Justin Pryzby <[email protected]>
  0 siblings, 0 replies; 8+ messages in thread

From: Justin Pryzby @ 2022-05-27 03:24 UTC (permalink / raw)

This reverts commit a17fd67d2f2861ae0ce00d1aeefdf2facc47cd5e.

TODO: partially revert 6b04abdfc5e0653542ac5d586e639185a8c61a39

See also:
a17fd67d2f2861ae0ce00d1aeefdf2facc47cd5e
https://www.postgresql.org/message-id/20220416144454.GX26620%40telsasoft.com

ci-os-only: windows
---
 src/interfaces/libpq/test/Makefile |  6 ++---
 src/tools/msvc/Mkvcbuild.pm        | 36 +++++++++++++-----------------
 2 files changed, 18 insertions(+), 24 deletions(-)

diff --git a/src/interfaces/libpq/test/Makefile b/src/interfaces/libpq/test/Makefile
index 1f75b73b8c1..d8e5ae824f2 100644
--- a/src/interfaces/libpq/test/Makefile
+++ b/src/interfaces/libpq/test/Makefile
@@ -11,9 +11,9 @@ endif
 override CPPFLAGS := -I$(libpq_srcdir) $(CPPFLAGS)
 LDFLAGS_INTERNAL += $(libpq_pgport)
 
-PROGS = libpq_testclient libpq_uri_regress
+PROGRAMS = libpq_testclient libpq_uri_regress
 
-all: $(PROGS)
+all: $(PROGRAMS)
 
 clean distclean maintainer-clean:
-	rm -f $(PROGS) *.o
+	rm -f $(PROGRAMS) *.o
diff --git a/src/tools/msvc/Mkvcbuild.pm b/src/tools/msvc/Mkvcbuild.pm
index e4feda10fd8..1de77075724 100644
--- a/src/tools/msvc/Mkvcbuild.pm
+++ b/src/tools/msvc/Mkvcbuild.pm
@@ -37,11 +37,14 @@ my @unlink_on_exit;
 # Set of variables for modules in contrib/ and src/test/modules/
 my $contrib_defines        = {};
 my @contrib_uselibpq       = ();
-my @contrib_uselibpgport   = ();
+my @contrib_uselibpgport   = ('libpq_uri_regress', 'libpq_testclient');
 my @contrib_uselibpgcommon = ();
 my $contrib_extralibs      = { 'libpq_pipeline' => ['ws2_32.lib'] };
 my $contrib_extraincludes  = {};
-my $contrib_extrasource    = {};
+my $contrib_extrasource    = {
+	'libpq_uri_regress' => ['src/interfaces/libpq/test/libpq_uri_regress.c'],
+	'libpq_testclient'  => ['src/interfaces/libpq/test/libpq_testclient.c'],
+};
 my @contrib_excludes       = (
 	'bool_plperl',     'commit_ts',
 	'hstore_plperl',   'hstore_plpython',
@@ -284,24 +287,6 @@ sub mkvcbuild
 	$libpqwalreceiver->AddIncludeDir('src/interfaces/libpq');
 	$libpqwalreceiver->AddReference($postgres, $libpq);
 
-	my $libpq_testclient =
-	  $solution->AddProject('libpq_testclient', 'exe', 'misc',
-		'src/interfaces/libpq/test');
-	$libpq_testclient->AddFile(
-		'src/interfaces/libpq/test/libpq_testclient.c');
-	$libpq_testclient->AddIncludeDir('src/interfaces/libpq');
-	$libpq_testclient->AddReference($libpgport, $libpq);
-	$libpq_testclient->AddLibrary('ws2_32.lib');
-
-	my $libpq_uri_regress =
-	  $solution->AddProject('libpq_uri_regress', 'exe', 'misc',
-		'src/interfaces/libpq/test');
-	$libpq_uri_regress->AddFile(
-		'src/interfaces/libpq/test/libpq_uri_regress.c');
-	$libpq_uri_regress->AddIncludeDir('src/interfaces/libpq');
-	$libpq_uri_regress->AddReference($libpgport, $libpq);
-	$libpq_uri_regress->AddLibrary('ws2_32.lib');
-
 	my $pgoutput = $solution->AddProject('pgoutput', 'dll', '',
 		'src/backend/replication/pgoutput');
 	$pgoutput->AddReference($postgres);
@@ -475,7 +460,7 @@ sub mkvcbuild
 		push @contrib_excludes, 'uuid-ossp';
 	}
 
-	foreach my $subdir ('contrib', 'src/test/modules')
+	foreach my $subdir ('contrib', 'src/test/modules', 'src/interfaces/libpq')
 	{
 		opendir($D, $subdir) || croak "Could not opendir on $subdir!\n";
 		while (my $d = readdir($D))
@@ -986,6 +971,15 @@ sub AddContrib
 		AdjustContribProj($proj);
 		push @projects, $proj;
 	}
+	elsif ($mf =~ /^PROGRAMS\s*=\s*(.*)$/mg)
+	{
+		foreach my $proj (split /\s+/, $1)
+		{
+			my $p = $solution->AddProject($proj, 'exe', 'contrib', "$subdir/$n");
+			AdjustContribProj($p);
+			push @projects, $p;
+		}
+	}
 	else
 	{
 		croak "Could not determine contrib module type for $n\n";
-- 
2.17.1


--Sw7tCqrGA+HQ0/zt
Content-Type: text/x-diff; charset=us-ascii
Content-Disposition: attachment;
 filename="0014-Move-libpq_pipeline-test-into-src-interfaces-libpq.patch"



^ permalink  raw  reply  [nested|flat] 8+ messages in thread

* [PATCH 14/21] another way to install uri-regress/uri_regress
@ 2022-05-27 03:24  Justin Pryzby <[email protected]>
  0 siblings, 0 replies; 8+ messages in thread

From: Justin Pryzby @ 2022-05-27 03:24 UTC (permalink / raw)

This reverts commit a17fd67d2f2861ae0ce00d1aeefdf2facc47cd5e.

TODO: partially revert 6b04abdfc5e0653542ac5d586e639185a8c61a39

See also:
a17fd67d2f2861ae0ce00d1aeefdf2facc47cd5e
https://www.postgresql.org/message-id/20220416144454.GX26620%40telsasoft.com
https://www.postgresql.org/message-id/20220223211606.ikcwoolsz2nohsw6%40alap3.anarazel.de

TODO: doc/src/sgml/extend.sgml

ci-os-only: linux, windows
---
 src/interfaces/libpq/test/Makefile |  6 ++---
 src/tools/msvc/Mkvcbuild.pm        | 36 +++++++++++++-----------------
 2 files changed, 18 insertions(+), 24 deletions(-)

diff --git a/src/interfaces/libpq/test/Makefile b/src/interfaces/libpq/test/Makefile
index 1f75b73b8c1..d8e5ae824f2 100644
--- a/src/interfaces/libpq/test/Makefile
+++ b/src/interfaces/libpq/test/Makefile
@@ -11,9 +11,9 @@ endif
 override CPPFLAGS := -I$(libpq_srcdir) $(CPPFLAGS)
 LDFLAGS_INTERNAL += $(libpq_pgport)
 
-PROGS = libpq_testclient libpq_uri_regress
+PROGRAMS = libpq_testclient libpq_uri_regress
 
-all: $(PROGS)
+all: $(PROGRAMS)
 
 clean distclean maintainer-clean:
-	rm -f $(PROGS) *.o
+	rm -f $(PROGRAMS) *.o
diff --git a/src/tools/msvc/Mkvcbuild.pm b/src/tools/msvc/Mkvcbuild.pm
index e4feda10fd8..1de77075724 100644
--- a/src/tools/msvc/Mkvcbuild.pm
+++ b/src/tools/msvc/Mkvcbuild.pm
@@ -37,11 +37,14 @@ my @unlink_on_exit;
 # Set of variables for modules in contrib/ and src/test/modules/
 my $contrib_defines        = {};
 my @contrib_uselibpq       = ();
-my @contrib_uselibpgport   = ();
+my @contrib_uselibpgport   = ('libpq_uri_regress', 'libpq_testclient');
 my @contrib_uselibpgcommon = ();
 my $contrib_extralibs      = { 'libpq_pipeline' => ['ws2_32.lib'] };
 my $contrib_extraincludes  = {};
-my $contrib_extrasource    = {};
+my $contrib_extrasource    = {
+	'libpq_uri_regress' => ['src/interfaces/libpq/test/libpq_uri_regress.c'],
+	'libpq_testclient'  => ['src/interfaces/libpq/test/libpq_testclient.c'],
+};
 my @contrib_excludes       = (
 	'bool_plperl',     'commit_ts',
 	'hstore_plperl',   'hstore_plpython',
@@ -284,24 +287,6 @@ sub mkvcbuild
 	$libpqwalreceiver->AddIncludeDir('src/interfaces/libpq');
 	$libpqwalreceiver->AddReference($postgres, $libpq);
 
-	my $libpq_testclient =
-	  $solution->AddProject('libpq_testclient', 'exe', 'misc',
-		'src/interfaces/libpq/test');
-	$libpq_testclient->AddFile(
-		'src/interfaces/libpq/test/libpq_testclient.c');
-	$libpq_testclient->AddIncludeDir('src/interfaces/libpq');
-	$libpq_testclient->AddReference($libpgport, $libpq);
-	$libpq_testclient->AddLibrary('ws2_32.lib');
-
-	my $libpq_uri_regress =
-	  $solution->AddProject('libpq_uri_regress', 'exe', 'misc',
-		'src/interfaces/libpq/test');
-	$libpq_uri_regress->AddFile(
-		'src/interfaces/libpq/test/libpq_uri_regress.c');
-	$libpq_uri_regress->AddIncludeDir('src/interfaces/libpq');
-	$libpq_uri_regress->AddReference($libpgport, $libpq);
-	$libpq_uri_regress->AddLibrary('ws2_32.lib');
-
 	my $pgoutput = $solution->AddProject('pgoutput', 'dll', '',
 		'src/backend/replication/pgoutput');
 	$pgoutput->AddReference($postgres);
@@ -475,7 +460,7 @@ sub mkvcbuild
 		push @contrib_excludes, 'uuid-ossp';
 	}
 
-	foreach my $subdir ('contrib', 'src/test/modules')
+	foreach my $subdir ('contrib', 'src/test/modules', 'src/interfaces/libpq')
 	{
 		opendir($D, $subdir) || croak "Could not opendir on $subdir!\n";
 		while (my $d = readdir($D))
@@ -986,6 +971,15 @@ sub AddContrib
 		AdjustContribProj($proj);
 		push @projects, $proj;
 	}
+	elsif ($mf =~ /^PROGRAMS\s*=\s*(.*)$/mg)
+	{
+		foreach my $proj (split /\s+/, $1)
+		{
+			my $p = $solution->AddProject($proj, 'exe', 'contrib', "$subdir/$n");
+			AdjustContribProj($p);
+			push @projects, $p;
+		}
+	}
 	else
 	{
 		croak "Could not determine contrib module type for $n\n";
-- 
2.17.1


--STPqjqpCrtky8aYs
Content-Type: text/x-diff; charset=us-ascii
Content-Disposition: attachment;
 filename="0015-Move-libpq_pipeline-test-into-src-interfaces-libpq.patch"



^ permalink  raw  reply  [nested|flat] 8+ messages in thread

* [PATCH 13/19] another way to install uri-regress/uri_regress
@ 2022-05-27 03:24  Justin Pryzby <[email protected]>
  0 siblings, 0 replies; 8+ messages in thread

From: Justin Pryzby @ 2022-05-27 03:24 UTC (permalink / raw)

This reverts commit a17fd67d2f2861ae0ce00d1aeefdf2facc47cd5e.

TODO: partially revert 6b04abdfc5e0653542ac5d586e639185a8c61a39

See also:
a17fd67d2f2861ae0ce00d1aeefdf2facc47cd5e
https://www.postgresql.org/message-id/20220416144454.GX26620%40telsasoft.com

ci-os-only: windows
---
 src/interfaces/libpq/test/Makefile |  6 ++---
 src/tools/msvc/Mkvcbuild.pm        | 36 +++++++++++++-----------------
 2 files changed, 18 insertions(+), 24 deletions(-)

diff --git a/src/interfaces/libpq/test/Makefile b/src/interfaces/libpq/test/Makefile
index 1f75b73b8c1..d8e5ae824f2 100644
--- a/src/interfaces/libpq/test/Makefile
+++ b/src/interfaces/libpq/test/Makefile
@@ -11,9 +11,9 @@ endif
 override CPPFLAGS := -I$(libpq_srcdir) $(CPPFLAGS)
 LDFLAGS_INTERNAL += $(libpq_pgport)
 
-PROGS = libpq_testclient libpq_uri_regress
+PROGRAMS = libpq_testclient libpq_uri_regress
 
-all: $(PROGS)
+all: $(PROGRAMS)
 
 clean distclean maintainer-clean:
-	rm -f $(PROGS) *.o
+	rm -f $(PROGRAMS) *.o
diff --git a/src/tools/msvc/Mkvcbuild.pm b/src/tools/msvc/Mkvcbuild.pm
index e4feda10fd8..1de77075724 100644
--- a/src/tools/msvc/Mkvcbuild.pm
+++ b/src/tools/msvc/Mkvcbuild.pm
@@ -37,11 +37,14 @@ my @unlink_on_exit;
 # Set of variables for modules in contrib/ and src/test/modules/
 my $contrib_defines        = {};
 my @contrib_uselibpq       = ();
-my @contrib_uselibpgport   = ();
+my @contrib_uselibpgport   = ('libpq_uri_regress', 'libpq_testclient');
 my @contrib_uselibpgcommon = ();
 my $contrib_extralibs      = { 'libpq_pipeline' => ['ws2_32.lib'] };
 my $contrib_extraincludes  = {};
-my $contrib_extrasource    = {};
+my $contrib_extrasource    = {
+	'libpq_uri_regress' => ['src/interfaces/libpq/test/libpq_uri_regress.c'],
+	'libpq_testclient'  => ['src/interfaces/libpq/test/libpq_testclient.c'],
+};
 my @contrib_excludes       = (
 	'bool_plperl',     'commit_ts',
 	'hstore_plperl',   'hstore_plpython',
@@ -284,24 +287,6 @@ sub mkvcbuild
 	$libpqwalreceiver->AddIncludeDir('src/interfaces/libpq');
 	$libpqwalreceiver->AddReference($postgres, $libpq);
 
-	my $libpq_testclient =
-	  $solution->AddProject('libpq_testclient', 'exe', 'misc',
-		'src/interfaces/libpq/test');
-	$libpq_testclient->AddFile(
-		'src/interfaces/libpq/test/libpq_testclient.c');
-	$libpq_testclient->AddIncludeDir('src/interfaces/libpq');
-	$libpq_testclient->AddReference($libpgport, $libpq);
-	$libpq_testclient->AddLibrary('ws2_32.lib');
-
-	my $libpq_uri_regress =
-	  $solution->AddProject('libpq_uri_regress', 'exe', 'misc',
-		'src/interfaces/libpq/test');
-	$libpq_uri_regress->AddFile(
-		'src/interfaces/libpq/test/libpq_uri_regress.c');
-	$libpq_uri_regress->AddIncludeDir('src/interfaces/libpq');
-	$libpq_uri_regress->AddReference($libpgport, $libpq);
-	$libpq_uri_regress->AddLibrary('ws2_32.lib');
-
 	my $pgoutput = $solution->AddProject('pgoutput', 'dll', '',
 		'src/backend/replication/pgoutput');
 	$pgoutput->AddReference($postgres);
@@ -475,7 +460,7 @@ sub mkvcbuild
 		push @contrib_excludes, 'uuid-ossp';
 	}
 
-	foreach my $subdir ('contrib', 'src/test/modules')
+	foreach my $subdir ('contrib', 'src/test/modules', 'src/interfaces/libpq')
 	{
 		opendir($D, $subdir) || croak "Could not opendir on $subdir!\n";
 		while (my $d = readdir($D))
@@ -986,6 +971,15 @@ sub AddContrib
 		AdjustContribProj($proj);
 		push @projects, $proj;
 	}
+	elsif ($mf =~ /^PROGRAMS\s*=\s*(.*)$/mg)
+	{
+		foreach my $proj (split /\s+/, $1)
+		{
+			my $p = $solution->AddProject($proj, 'exe', 'contrib', "$subdir/$n");
+			AdjustContribProj($p);
+			push @projects, $p;
+		}
+	}
 	else
 	{
 		croak "Could not determine contrib module type for $n\n";
-- 
2.17.1


--Sw7tCqrGA+HQ0/zt
Content-Type: text/x-diff; charset=us-ascii
Content-Disposition: attachment;
 filename="0014-Move-libpq_pipeline-test-into-src-interfaces-libpq.patch"



^ permalink  raw  reply  [nested|flat] 8+ messages in thread

* [PATCH 13/19] another way to install uri-regress/uri_regress
@ 2022-05-27 03:24  Justin Pryzby <[email protected]>
  0 siblings, 0 replies; 8+ messages in thread

From: Justin Pryzby @ 2022-05-27 03:24 UTC (permalink / raw)

This reverts commit a17fd67d2f2861ae0ce00d1aeefdf2facc47cd5e.

TODO: partially revert 6b04abdfc5e0653542ac5d586e639185a8c61a39

See also:
a17fd67d2f2861ae0ce00d1aeefdf2facc47cd5e
https://www.postgresql.org/message-id/20220416144454.GX26620%40telsasoft.com

ci-os-only: windows
---
 src/interfaces/libpq/test/Makefile |  6 ++---
 src/tools/msvc/Mkvcbuild.pm        | 36 +++++++++++++-----------------
 2 files changed, 18 insertions(+), 24 deletions(-)

diff --git a/src/interfaces/libpq/test/Makefile b/src/interfaces/libpq/test/Makefile
index 1f75b73b8c1..d8e5ae824f2 100644
--- a/src/interfaces/libpq/test/Makefile
+++ b/src/interfaces/libpq/test/Makefile
@@ -11,9 +11,9 @@ endif
 override CPPFLAGS := -I$(libpq_srcdir) $(CPPFLAGS)
 LDFLAGS_INTERNAL += $(libpq_pgport)
 
-PROGS = libpq_testclient libpq_uri_regress
+PROGRAMS = libpq_testclient libpq_uri_regress
 
-all: $(PROGS)
+all: $(PROGRAMS)
 
 clean distclean maintainer-clean:
-	rm -f $(PROGS) *.o
+	rm -f $(PROGRAMS) *.o
diff --git a/src/tools/msvc/Mkvcbuild.pm b/src/tools/msvc/Mkvcbuild.pm
index e4feda10fd8..1de77075724 100644
--- a/src/tools/msvc/Mkvcbuild.pm
+++ b/src/tools/msvc/Mkvcbuild.pm
@@ -37,11 +37,14 @@ my @unlink_on_exit;
 # Set of variables for modules in contrib/ and src/test/modules/
 my $contrib_defines        = {};
 my @contrib_uselibpq       = ();
-my @contrib_uselibpgport   = ();
+my @contrib_uselibpgport   = ('libpq_uri_regress', 'libpq_testclient');
 my @contrib_uselibpgcommon = ();
 my $contrib_extralibs      = { 'libpq_pipeline' => ['ws2_32.lib'] };
 my $contrib_extraincludes  = {};
-my $contrib_extrasource    = {};
+my $contrib_extrasource    = {
+	'libpq_uri_regress' => ['src/interfaces/libpq/test/libpq_uri_regress.c'],
+	'libpq_testclient'  => ['src/interfaces/libpq/test/libpq_testclient.c'],
+};
 my @contrib_excludes       = (
 	'bool_plperl',     'commit_ts',
 	'hstore_plperl',   'hstore_plpython',
@@ -284,24 +287,6 @@ sub mkvcbuild
 	$libpqwalreceiver->AddIncludeDir('src/interfaces/libpq');
 	$libpqwalreceiver->AddReference($postgres, $libpq);
 
-	my $libpq_testclient =
-	  $solution->AddProject('libpq_testclient', 'exe', 'misc',
-		'src/interfaces/libpq/test');
-	$libpq_testclient->AddFile(
-		'src/interfaces/libpq/test/libpq_testclient.c');
-	$libpq_testclient->AddIncludeDir('src/interfaces/libpq');
-	$libpq_testclient->AddReference($libpgport, $libpq);
-	$libpq_testclient->AddLibrary('ws2_32.lib');
-
-	my $libpq_uri_regress =
-	  $solution->AddProject('libpq_uri_regress', 'exe', 'misc',
-		'src/interfaces/libpq/test');
-	$libpq_uri_regress->AddFile(
-		'src/interfaces/libpq/test/libpq_uri_regress.c');
-	$libpq_uri_regress->AddIncludeDir('src/interfaces/libpq');
-	$libpq_uri_regress->AddReference($libpgport, $libpq);
-	$libpq_uri_regress->AddLibrary('ws2_32.lib');
-
 	my $pgoutput = $solution->AddProject('pgoutput', 'dll', '',
 		'src/backend/replication/pgoutput');
 	$pgoutput->AddReference($postgres);
@@ -475,7 +460,7 @@ sub mkvcbuild
 		push @contrib_excludes, 'uuid-ossp';
 	}
 
-	foreach my $subdir ('contrib', 'src/test/modules')
+	foreach my $subdir ('contrib', 'src/test/modules', 'src/interfaces/libpq')
 	{
 		opendir($D, $subdir) || croak "Could not opendir on $subdir!\n";
 		while (my $d = readdir($D))
@@ -986,6 +971,15 @@ sub AddContrib
 		AdjustContribProj($proj);
 		push @projects, $proj;
 	}
+	elsif ($mf =~ /^PROGRAMS\s*=\s*(.*)$/mg)
+	{
+		foreach my $proj (split /\s+/, $1)
+		{
+			my $p = $solution->AddProject($proj, 'exe', 'contrib', "$subdir/$n");
+			AdjustContribProj($p);
+			push @projects, $p;
+		}
+	}
 	else
 	{
 		croak "Could not determine contrib module type for $n\n";
-- 
2.17.1


--Sw7tCqrGA+HQ0/zt
Content-Type: text/x-diff; charset=us-ascii
Content-Disposition: attachment;
 filename="0014-Move-libpq_pipeline-test-into-src-interfaces-libpq.patch"



^ permalink  raw  reply  [nested|flat] 8+ messages in thread

* [PATCH 14/21] another way to install uri-regress/uri_regress
@ 2022-05-27 03:24  Justin Pryzby <[email protected]>
  0 siblings, 0 replies; 8+ messages in thread

From: Justin Pryzby @ 2022-05-27 03:24 UTC (permalink / raw)

This reverts commit a17fd67d2f2861ae0ce00d1aeefdf2facc47cd5e.

TODO: partially revert 6b04abdfc5e0653542ac5d586e639185a8c61a39

See also:
a17fd67d2f2861ae0ce00d1aeefdf2facc47cd5e
https://www.postgresql.org/message-id/20220416144454.GX26620%40telsasoft.com
https://www.postgresql.org/message-id/20220223211606.ikcwoolsz2nohsw6%40alap3.anarazel.de

TODO: doc/src/sgml/extend.sgml

ci-os-only: linux, windows
---
 src/interfaces/libpq/test/Makefile |  8 +++----
 src/tools/msvc/Mkvcbuild.pm        | 36 +++++++++++++-----------------
 2 files changed, 19 insertions(+), 25 deletions(-)

diff --git a/src/interfaces/libpq/test/Makefile b/src/interfaces/libpq/test/Makefile
index 75ac08f943d..91c8d87d528 100644
--- a/src/interfaces/libpq/test/Makefile
+++ b/src/interfaces/libpq/test/Makefile
@@ -14,11 +14,11 @@ endif
 override CPPFLAGS := -I$(libpq_srcdir) $(CPPFLAGS)
 LDFLAGS_INTERNAL += $(libpq_pgport)
 
-PROGS = libpq_testclient libpq_uri_regress
+PROGRAMS = libpq_testclient libpq_uri_regress
 
-all: $(PROGS)
+all: $(PROGRAMS)
 
-$(PROGS): $(WIN32RES)
+$(PROGRAMS): $(WIN32RES)
 
 clean distclean maintainer-clean:
-	rm -f $(PROGS) *.o
+	rm -f $(PROGRAMS) *.o
diff --git a/src/tools/msvc/Mkvcbuild.pm b/src/tools/msvc/Mkvcbuild.pm
index e4feda10fd8..1de77075724 100644
--- a/src/tools/msvc/Mkvcbuild.pm
+++ b/src/tools/msvc/Mkvcbuild.pm
@@ -37,11 +37,14 @@ my @unlink_on_exit;
 # Set of variables for modules in contrib/ and src/test/modules/
 my $contrib_defines        = {};
 my @contrib_uselibpq       = ();
-my @contrib_uselibpgport   = ();
+my @contrib_uselibpgport   = ('libpq_uri_regress', 'libpq_testclient');
 my @contrib_uselibpgcommon = ();
 my $contrib_extralibs      = { 'libpq_pipeline' => ['ws2_32.lib'] };
 my $contrib_extraincludes  = {};
-my $contrib_extrasource    = {};
+my $contrib_extrasource    = {
+	'libpq_uri_regress' => ['src/interfaces/libpq/test/libpq_uri_regress.c'],
+	'libpq_testclient'  => ['src/interfaces/libpq/test/libpq_testclient.c'],
+};
 my @contrib_excludes       = (
 	'bool_plperl',     'commit_ts',
 	'hstore_plperl',   'hstore_plpython',
@@ -284,24 +287,6 @@ sub mkvcbuild
 	$libpqwalreceiver->AddIncludeDir('src/interfaces/libpq');
 	$libpqwalreceiver->AddReference($postgres, $libpq);
 
-	my $libpq_testclient =
-	  $solution->AddProject('libpq_testclient', 'exe', 'misc',
-		'src/interfaces/libpq/test');
-	$libpq_testclient->AddFile(
-		'src/interfaces/libpq/test/libpq_testclient.c');
-	$libpq_testclient->AddIncludeDir('src/interfaces/libpq');
-	$libpq_testclient->AddReference($libpgport, $libpq);
-	$libpq_testclient->AddLibrary('ws2_32.lib');
-
-	my $libpq_uri_regress =
-	  $solution->AddProject('libpq_uri_regress', 'exe', 'misc',
-		'src/interfaces/libpq/test');
-	$libpq_uri_regress->AddFile(
-		'src/interfaces/libpq/test/libpq_uri_regress.c');
-	$libpq_uri_regress->AddIncludeDir('src/interfaces/libpq');
-	$libpq_uri_regress->AddReference($libpgport, $libpq);
-	$libpq_uri_regress->AddLibrary('ws2_32.lib');
-
 	my $pgoutput = $solution->AddProject('pgoutput', 'dll', '',
 		'src/backend/replication/pgoutput');
 	$pgoutput->AddReference($postgres);
@@ -475,7 +460,7 @@ sub mkvcbuild
 		push @contrib_excludes, 'uuid-ossp';
 	}
 
-	foreach my $subdir ('contrib', 'src/test/modules')
+	foreach my $subdir ('contrib', 'src/test/modules', 'src/interfaces/libpq')
 	{
 		opendir($D, $subdir) || croak "Could not opendir on $subdir!\n";
 		while (my $d = readdir($D))
@@ -986,6 +971,15 @@ sub AddContrib
 		AdjustContribProj($proj);
 		push @projects, $proj;
 	}
+	elsif ($mf =~ /^PROGRAMS\s*=\s*(.*)$/mg)
+	{
+		foreach my $proj (split /\s+/, $1)
+		{
+			my $p = $solution->AddProject($proj, 'exe', 'contrib', "$subdir/$n");
+			AdjustContribProj($p);
+			push @projects, $p;
+		}
+	}
 	else
 	{
 		croak "Could not determine contrib module type for $n\n";
-- 
2.17.1


--mln0rGgUGuXEqmuI
Content-Type: text/x-diff; charset=us-ascii
Content-Disposition: attachment;
 filename="0015-Move-libpq_pipeline-test-into-src-interfaces-libpq.patch"



^ permalink  raw  reply  [nested|flat] 8+ messages in thread

* use correct variable in error message in _allocAH function (pg_backup_archiver.c)
@ 2025-04-14 22:21  Mahendra Singh Thalor <[email protected]>
  0 siblings, 0 replies; 8+ messages in thread

From: Mahendra Singh Thalor @ 2025-04-14 22:21 UTC (permalink / raw)
  To: PostgreSQL Hackers <[email protected]>

Hi hackers,

In _allocAH function(pg_backup_archiver.c), we were using the *fmt*
variable in switch case for *default case*, but correct variable is
AH->format.

Here, I am attaching a patch for the same.

-- 
Thanks and Regards
Mahendra Singh Thalor
EnterpriseDB: http://www.enterprisedb.com


Attachments:

  [application/octet-stream] v01-use-correct-variable-in-error-message-in-_allocAH-fun.patch (887B, ../../CAKYtNAqu+N-Ab2Fq6wzNSOm_-0N-BMneanYNV1+6kFDXjva1Eg@mail.gmail.com/3-v01-use-correct-variable-in-error-message-in-_allocAH-fun.patch)
  download | inline diff:
From b9ec096c2ed98e03aa95682a6ac243c2c1fc45e4 Mon Sep 17 00:00:00 2001
From: Mahendra Singh Thalor <[email protected]>
Date: Tue, 15 Apr 2025 03:43:01 +0530
Subject: [PATCH] use correct variable in error message in _allocAH function.

In _allocAH function, we were using fmt variable in switch case, but
correct is AH->format.
---
 src/bin/pg_dump/pg_backup_archiver.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/bin/pg_dump/pg_backup_archiver.c b/src/bin/pg_dump/pg_backup_archiver.c
index f961162f365..afa42337b11 100644
--- a/src/bin/pg_dump/pg_backup_archiver.c
+++ b/src/bin/pg_dump/pg_backup_archiver.c
@@ -2469,7 +2469,7 @@ _allocAH(const char *FileSpec, const ArchiveFormat fmt,
 			break;
 
 		default:
-			pg_fatal("unrecognized file format \"%d\"", fmt);
+			pg_fatal("unrecognized file format \"%d\"", AH->format);
 	}
 
 	return AH;
-- 
2.39.3



^ permalink  raw  reply  [nested|flat] 8+ messages in thread


end of thread, other threads:[~2025-04-14 22:21 UTC | newest]

Thread overview: 8+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2022-02-06 07:17 Re: pg_upgrade should truncate/remove its logs before running Tom Lane <[email protected]>
2022-02-06 13:32 ` Andrew Dunstan <[email protected]>
2022-05-27 03:24 [PATCH 13/19] another way to install uri-regress/uri_regress Justin Pryzby <[email protected]>
2022-05-27 03:24 [PATCH 13/19] another way to install uri-regress/uri_regress Justin Pryzby <[email protected]>
2022-05-27 03:24 [PATCH 14/21] another way to install uri-regress/uri_regress Justin Pryzby <[email protected]>
2022-05-27 03:24 [PATCH 13/19] another way to install uri-regress/uri_regress Justin Pryzby <[email protected]>
2022-05-27 03:24 [PATCH 14/21] another way to install uri-regress/uri_regress Justin Pryzby <[email protected]>
2025-04-14 22:21 use correct variable in error message in _allocAH function (pg_backup_archiver.c) Mahendra Singh Thalor <[email protected]>

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