>From 5b397a953f5ed897bc5f6861b05599063ac80b37 Mon Sep 17 00:00:00 2001 From: Matthias Paulmier
Date: Fri, 7 Sep 2018 18:17:40 +0200 Subject: [PATCH 3/4] Fix termination error for .plt test files We had an error where the STDOUT handler would be closed and then reopened because of the redefinition of END in the Automake::General library. Isolating this redefinition in its own file and including it only where it is needed (in bin/* scripts) fixes this error. - lib/Automake/End.pm: Add it and move END from General.pm to here. Fixes a termination bug where the STDOUT handler was closed and reopened --- bin/aclocal.in | 1 + bin/automake.in | 1 + lib/Automake/End.pm | 47 +++++++++++++++++++++++++++++++++++++++++ lib/Automake/General.pm | 24 +-------------------- lib/Automake/local.mk | 1 + 5 files changed, 51 insertions(+), 23 deletions(-) mode change 100644 => 100755 bin/aclocal.in create mode 100644 lib/Automake/End.pm diff --git a/bin/aclocal.in b/bin/aclocal.in old mode 100644 new mode 100755 index 722affa55..09d8b89de --- a/bin/aclocal.in +++ b/bin/aclocal.in @@ -34,6 +34,7 @@ use Automake::Channels; use Automake::ChannelDefs; use Automake::XFile; use Automake::FileUtils; +use Automake::End; use File::Basename; use File::Path (); diff --git a/bin/automake.in b/bin/automake.in index b4ae8f43f..8c783074b 100644 --- a/bin/automake.in +++ b/bin/automake.in @@ -55,6 +55,7 @@ use Automake::XFile; use Automake::Channels; use Automake::ChannelDefs; use Automake::Configure_ac; +use Automake::End; use Automake::FileUtils; use Automake::Location; use Automake::Condition qw/TRUE FALSE/; diff --git a/lib/Automake/End.pm b/lib/Automake/End.pm new file mode 100644 index 000000000..7946d814b --- /dev/null +++ b/lib/Automake/End.pm @@ -0,0 +1,47 @@ +# Copyright (C) 2018 Free Software Foundation, Inc. + +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. + +# You should have received a copy of the GNU General Public License +# along with this program. If not, see