From 6c2ae6421675ba5ff81dd43f9167136f02dfe9d9 Mon Sep 17 00:00:00 2001 From: Aaron Crane Date: Mon, 23 Oct 2017 17:22:34 +0100 Subject: RT#132347: fix building Tk The Tk distribution has its own portability layer that expects to find certain settings in %Config, as well as some cpp symbols defined in perl.h. The recent Perl changes to require a C89 compiler caused some of the metaconfig units defining those %Config settings and cpp symbols to be omitted. This commit restores compatibility with Tk, by ensuring that the things it wants are available even though they are no longer provided by metaconfig. --- configpm | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) (limited to 'configpm') diff --git a/configpm b/configpm index 09b9e67aab..ebbaaa9b44 100755 --- a/configpm +++ b/configpm @@ -212,6 +212,19 @@ my $in_v = 0; my %Data = (); my $quote; +# These variables were set in older versions of Perl, but are no longer needed +# by the core. However, some CPAN modules may rely on them; in particular, Tk +# (at least up to version 804.034) fails to build without them. We force them +# to be emitted to Config_heavy.pl for backcompat with such modules (and we may +# find that this set needs to be extended in future). See RT#132347. +my @v_forced = map "$_\n", split /\n+/, <<'EOT'; +i_limits='define' +i_stdlib='define' +i_string='define' +i_time='define' +prototype='define' +EOT + my %seen_quotes; { @@ -567,7 +580,7 @@ $heavy_txt .= join('', map { /^([^=]+)/ ? [ $1, $_ ] : [ $_, $_ ] # shouldnt happen - } @v_others + } @v_others, @v_forced ) . "!END!\n"; # Only need the dynamic byteorder code in Config.pm if 'byteorder' is one of -- cgit v1.2.1