From 69d530f1dbb5b41fda0c049ef97490f92a2a6fff Mon Sep 17 00:00:00 2001 From: Andrew Johnson Date: Fri, 16 Jun 2017 15:37:55 -0500 Subject: [PATCH] Cross-build fix for generated .t files The *target* OS should determine whether to use system or exec. --- src/tools/makeTestfile.pl | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/src/tools/makeTestfile.pl b/src/tools/makeTestfile.pl index 4ac5162db..be4648258 100644 --- a/src/tools/makeTestfile.pl +++ b/src/tools/makeTestfile.pl @@ -23,10 +23,6 @@ use strict; my ($target, $exe) = @ARGV; -# Use system on Windows, exec doesn't work the same there and -# GNUmake thinks the test has finished as soon as Perl exits. -my $exec = $^O eq 'MSWin32' ? "system('./$exe') == 0" : "exec './$exe'"; - open(my $OUT, '>', $target) or die "Can't create $target: $!\n"; print $OUT <