Commit 1933a5bb authored by Heikki Linnakangas's avatar Heikki Linnakangas

Make pg_xlogdump MSVC build work more like others.

Instead of copying xlogreader.c and *desc.c files into the source directory,
build them where they are. That's what we do for other binaries that need to
compile and link in files from elsewhere in the source tree.

The commit history suggests that it was done this way because of issues with
older versions of MSVC. I think this should work, but we'll see if the
buildfarm complains.
parent 30a5ce8f
...@@ -13,7 +13,6 @@ use Project; ...@@ -13,7 +13,6 @@ use Project;
use Solution; use Solution;
use Cwd; use Cwd;
use File::Copy; use File::Copy;
use File::Basename;
use Config; use Config;
use VSObjectFactory; use VSObjectFactory;
use List::Util qw(first); use List::Util qw(first);
...@@ -628,15 +627,11 @@ sub mkvcbuild ...@@ -628,15 +627,11 @@ sub mkvcbuild
(grep { $_->{name} eq 'pg_xlogdump' } (grep { $_->{name} eq 'pg_xlogdump' }
@{ $solution->{projects}->{contrib} })[0]; @{ $solution->{projects}->{contrib} })[0];
$pg_xlogdump->AddDefine('FRONTEND'); $pg_xlogdump->AddDefine('FRONTEND');
foreach my $xf (glob('src/backend/access/rmgrdesc/*desc.c')) foreach my $xf (glob('src\\backend\\access\\rmgrdesc\\*desc.c'))
{ {
my $bf = basename $xf; $pg_xlogdump->AddFile($xf)
copy($xf, "contrib/pg_xlogdump/$bf");
$pg_xlogdump->AddFile("contrib\\pg_xlogdump\\$bf");
} }
copy( $pg_xlogdump->AddFile('src\backend\access\transam\xlogreader.c');
'src/backend/access/transam/xlogreader.c',
'contrib/pg_xlogdump/xlogreader.c');
$solution->Save(); $solution->Save();
return $solution->{vcver}; return $solution->{vcver};
......
...@@ -92,11 +92,6 @@ REM Clean up datafiles built with contrib ...@@ -92,11 +92,6 @@ REM Clean up datafiles built with contrib
REM cd contrib REM cd contrib
REM for /r %%f in (*.sql) do if exist %%f.in del %%f REM for /r %%f in (*.sql) do if exist %%f.in del %%f
REM clean up files copied into contrib\pg_xlogdump
if exist contrib\pg_xlogdump\xlogreader.c del /q contrib\pg_xlogdump\xlogreader.c
for %%f in (contrib\pg_xlogdump\*desc.c) do if not %%f==contrib\pg_xlogdump\rmgrdesc.c del /q %%f
cd %D% cd %D%
REM Clean up ecpg regression test files REM Clean up ecpg regression test files
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment