Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitfdb8ea9

Browse files
committed
MSVC: Revert most 9.5 changes to pre-9.5 vcregress.pl tests.
The reverted changes did not narrow the semantic gap between the MSVCbuild system and the GNU make build system. For targets old and newthat run multiple suites (contribcheck, modulescheck, tapcheck), restorevcregress.pl to mimicking "make -k" rather than the "make -S" default.Lack of "-k" would be more burdensome than lack of "-S". Keep changesreflecting contemporary changes to the GNU make build system, and keepupdates to Makefile parsing. Keep the loss of --psqldir in "check" and"ecpgcheck" targets; it had been a no-op when used alongside--temp-install. No log message mentioned any of the reverted changes.Based on a germ by Michael Paquier. Back-patch to 9.5.
1 parent95eb4b2 commitfdb8ea9

File tree

1 file changed

+30
-39
lines changed

1 file changed

+30
-39
lines changed

‎src/tools/msvc/vcregress.pl

Lines changed: 30 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -108,15 +108,12 @@ sub installcheck
108108

109109
subcheck
110110
{
111-
chdir$startdir;
112-
113111
InstallTemp();
114112
chdir"${topdir}/src/test/regress";
115-
116113
my@args = (
117-
"${tmp_installdir}/bin/pg_regress",
114+
"../../../$Config/pg_regress/pg_regress",
118115
"--dlpath=.",
119-
"--bindir=${tmp_installdir}/bin",
116+
"--bindir=",
120117
"--schedule=${schedule}_schedule",
121118
"--encoding=SQL_ASCII",
122119
"--no-locale",
@@ -136,11 +133,9 @@ sub ecpgcheck
136133
exit$statusif$status;
137134
InstallTemp();
138135
chdir"$topdir/src/interfaces/ecpg/test";
139-
140-
$ENV{PATH} ="${tmp_installdir}/bin;${tmp_installdir}/lib;$ENV{PATH}";
141136
$schedule ="ecpg";
142137
my@args = (
143-
"${tmp_installdir}/bin/pg_regress_ecpg",
138+
"../../../../$Config/pg_regress_ecpg/pg_regress_ecpg",
144139
"--bindir=",
145140
"--dbname=regress1,connectdb",
146141
"--create-role=connectuser,connectdb",
@@ -156,14 +151,12 @@ sub ecpgcheck
156151

157152
subisolationcheck
158153
{
159-
chdir$startdir;
160-
161-
InstallTemp();
162-
chdir"${topdir}/src/test/isolation";
163-
154+
chdir"../isolation";
155+
copy("../../../$Config/isolationtester/isolationtester.exe",
156+
"../../../$Config/pg_isolation_regress");
164157
my@args = (
165-
"${tmp_installdir}/bin/pg_isolation_regress",
166-
"--bindir=${tmp_installdir}/bin",
158+
"../../../$Config/pg_isolation_regress/pg_isolation_regress",
159+
"--bindir=../../../$Config/psql",
167160
"--inputdir=.",
168161
"--schedule=./isolation_schedule");
169162
push(@args,$maxconn)if$maxconn;
@@ -174,10 +167,7 @@ sub isolationcheck
174167

175168
subplcheck
176169
{
177-
chdir$startdir;
178-
179-
InstallTemp();
180-
chdir"${topdir}/src/pl";
170+
chdir"../../pl";
181171

182172
foreachmy$pl (glob("*"))
183173
{
@@ -214,8 +204,8 @@ sub plcheck
214204
"============================================================\n";
215205
print"Checking$lang\n";
216206
my@args = (
217-
"${tmp_installdir}/bin/pg_regress",
218-
"--bindir=${tmp_installdir}/bin",
207+
"../../../$Config/pg_regress/pg_regress",
208+
"--bindir=../../../$Config/psql",
219209
"--dbname=pl_regression",@lang_args,@tests);
220210
system(@args);
221211
my$status =$? >> 8;
@@ -230,7 +220,6 @@ sub subdircheck
230220
{
231221
my$subdir =shift;
232222
my$module =shift;
233-
my$mstat = 0;
234223

235224
if ( !-d"$module/sql"
236225
|| !-d"$module/expected"
@@ -277,24 +266,19 @@ sub subdircheck
277266
print"============================================================\n";
278267
print"Checking$module\n";
279268
my@args = (
280-
"${tmp_installdir}/bin/pg_regress",
281-
"--bindir=${tmp_installdir}/bin",
269+
"$topdir/$Config/pg_regress/pg_regress",
270+
"--bindir=${topdir}/${Config}/psql",
282271
"--dbname=contrib_regression",@opts,@tests);
283272
system(@args);
284-
my$status =$? >> 8;
285-
$mstat ||=$status;
286273
chdir"..";
287-
288-
exit$mstatif$mstat;
289274
}
290275

291276
subcontribcheck
292277
{
293-
InstallTemp();
294-
chdir"$topdir/contrib";
278+
chdir"../../../contrib";
279+
my$mstat = 0;
295280
foreachmy$module (glob("*"))
296281
{
297-
298282
# these configuration-based exclusions must match Install.pm
299283
nextif ($moduleeq"uuid-ossp" && !defined($config->{uuid}));
300284
nextif ($moduleeq"sslinfo" && !defined($config->{openssl}));
@@ -305,26 +289,31 @@ sub contribcheck
305289
nextif ($moduleeq"sepgsql");
306290

307291
subdircheck("$topdir/contrib",$module);
292+
my$status =$? >> 8;
293+
$mstat ||=$status;
308294
}
295+
exit$mstatif$mstat;
309296
}
310297

311298
submodulescheck
312299
{
313-
InstallTemp();
314-
chdir"$topdir/src/test/modules";
300+
chdir"../../../src/test/modules";
301+
my$mstat = 0;
315302
foreachmy$module (glob("*"))
316303
{
317304
subdircheck("$topdir/src/test/modules",$module);
305+
my$status =$? >> 8;
306+
$mstat ||=$status;
318307
}
308+
exit$mstatif$mstat;
319309
}
320310

321-
322311
# Run "initdb", then reconfigure authentication.
323312
substandard_initdb
324313
{
325314
return (
326-
system("${tmp_installdir}/bin/initdb",'-N') == 0andsystem(
327-
"${tmp_installdir}/bin/pg_regress",'--config-auth',
315+
system('initdb','-N') == 0andsystem(
316+
"$topdir/$Config/pg_regress/pg_regress",'--config-auth',
328317
$ENV{PGDATA}) == 0);
329318
}
330319

@@ -343,13 +332,14 @@ sub upgradecheck
343332
$ENV{PGPORT} ||= 50432;
344333
my$tmp_root ="$topdir/src/bin/pg_upgrade/tmp_check";
345334
(mkdir$tmp_root ||die$!)unless-d$tmp_root;
346-
347-
InstallTemp();
335+
my$upg_tmp_install ="$tmp_root/install";# unshared temp install
336+
print"Setting up temp install\n\n";
337+
Install($upg_tmp_install,"all",$config);
348338

349339
# Install does a chdir, so change back after that
350340
chdir$cwd;
351341
my ($bindir,$libdir,$oldsrc,$newsrc) =
352-
("$tmp_installdir/bin","$tmp_installdir/lib",$topdir,$topdir);
342+
("$upg_tmp_install/bin","$upg_tmp_install/lib",$topdir,$topdir);
353343
$ENV{PATH} ="$bindir;$ENV{PATH}";
354344
my$data ="$tmp_root/data";
355345
$ENV{PGDATA} ="$data.old";
@@ -488,6 +478,7 @@ sub InstallTemp
488478
{
489479
print"Setting up temp install\n\n";
490480
Install("$tmp_installdir","all",$config);
481+
$ENV{PATH} ="$tmp_installdir/bin;$ENV{PATH}";
491482
}
492483

493484
subusage

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp