Re: pgsql: Move pg_dump memory routines into pg_dumpmem.c/h and restore com

From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: Bruce Momjian <bruce(at)momjian(dot)us>
Cc: pgsql-committers(at)postgresql(dot)org, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: pgsql: Move pg_dump memory routines into pg_dumpmem.c/h and restore com
Date: 2011-11-27 14:23:16
Message-ID: 4ED247D4.3060806@dunslane.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers pgsql-hackers

On 11/26/2011 10:36 PM, Bruce Momjian wrote:
> Move pg_dump memory routines into pg_dumpmem.c/h and restore common.c
> with its original functions. The previous function migration would
> cause too many difficulties in back-patching.

MSVC is still broken with this change, but now I think we've exposed a
long-standing error in the MSVC build system.

Mkvcbuild.pm has:

my $pgdumpall = AddSimpleFrontend('pg_dump', 1);
$pgdumpall->{name} = 'pg_dumpall';
$pgdumpall->AddIncludeDir('src\backend');
$pgdumpall->AddFile('src\bin\pg_dump\pg_dumpall.c');
$pgdumpall->AddFile('src\bin\pg_dump\keywords.c');
$pgdumpall->AddFile('src\backend\parser\kwlookup.c')

AddSimpleFrontend() calls AddDir() which harvests the contents of
$(OBJS) from the Makefile for the target. But pg_dumpall doesn't want
$(OBJS). We've been benignly but mistakenly building it with them for a
quite a few years, but now we can't do that any more, given Bruce's
changes. It looks like the fix is to call AddProject() for pg_dumpall
instead of AddSimpleFrontend() and then do a little more work ourselves
to select exactly what we need.

I don't have time to do that and test it immediately, as I'll be away
most of the day, so if anyone else can please go for it.

cheers

andrew

In response to

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2011-11-27 17:42:59 Re: pgsql: Move pg_dump memory routines into pg_dumpmem.c/h and restore com
Previous Message Andrew Dunstan 2011-11-27 06:24:13 pgsql: Fix MSVC builds broken by xsubpp change

Browse pgsql-hackers by date

  From Date Subject
Next Message Florian Weimer 2011-11-27 15:24:34 Large number of open(2) calls with bulk INSERT into empty table
Previous Message NISHIYAMA Tomoaki 2011-11-27 14:18:45 Re: [PATCH] PostgreSQL fails to build with 32bit MinGW-w64