summaryrefslogtreecommitdiff
path: root/cpan/Compress-Raw-Zlib/Makefile.PL
diff options
context:
space:
mode:
authorChris 'BinGOs' Williams <chris@bingosnet.co.uk>2010-06-30 09:56:41 +0100
committerChris 'BinGOs' Williams <chris@bingosnet.co.uk>2010-06-30 11:23:40 +0100
commitf02c02ec7c7eacaf7e719fe18388c537a795ae7e (patch)
tree89d1a7479b81db7146744e28f3e5112be5f8bc00 /cpan/Compress-Raw-Zlib/Makefile.PL
parent6f7e83539961a11c89e33c98b9799323e732d5f9 (diff)
downloadperl-f02c02ec7c7eacaf7e719fe18388c537a795ae7e.tar.gz
Update Compress-Raw-Zlib to CPAN version 2.027
[DELTA] 2.027 24 April 2010 * Updated to include zlib 1.2.5 2.026 7 April 2010 * Fixed definition of Z_TREES in Makefile.PL [RT #65293] * Fixed build issue with definition of off64_t not found on Solaris by modifying the zlib source - changed the symbol _LARGEFILE64_SOURCE to _LARGEFILE64_SOURCE_dummy in zconf.h, zlib.h and zutil.h [RT #56108] 2.025 27 March 2010 * Updated to include zlib 1.2.4 * Allow zlib version check to be disabled by setting TEST_SKIP_VERSION_CHECK environment variable. [RT #54510] 2.023 9 November 2009 * fixed instance where $[ should have been $] in t/02zlib.t Thanks to Robin Barker and zefram [RT #50765] for independantly spotting the issue.
Diffstat (limited to 'cpan/Compress-Raw-Zlib/Makefile.PL')
-rw-r--r--cpan/Compress-Raw-Zlib/Makefile.PL23
1 files changed, 21 insertions, 2 deletions
diff --git a/cpan/Compress-Raw-Zlib/Makefile.PL b/cpan/Compress-Raw-Zlib/Makefile.PL
index d141df42a0..aa6f5c0053 100644
--- a/cpan/Compress-Raw-Zlib/Makefile.PL
+++ b/cpan/Compress-Raw-Zlib/Makefile.PL
@@ -89,6 +89,14 @@ WriteMakefile(
) ;
+sub version_Macro
+{
+ my $ver = shift ;
+
+ return [ "#if ZLIB_VERNUM >= 0x$ver\n", "#endif\n" ];
+}
+
+
my @names = qw(
DEF_WBITS
@@ -129,9 +137,13 @@ my @names = qw(
);
#ZLIB_VERNUM
+my %verSpecificNames = (
+ Z_TREES => '1240',
+);
+
if (eval {require ExtUtils::Constant; 1}) {
# Check the constants above all appear in @EXPORT in Zlib.pm
- my %names = map { $_, 1} @names, 'ZLIB_VERSION';
+ my %names = %verSpecificNames, map { $_, 1} @names, 'ZLIB_VERSION';
open F, "<lib/Compress/Raw/Zlib.pm" or die "Cannot open Zlib.pm: $!\n";
while (<F>)
{
@@ -153,7 +165,13 @@ if (eval {require ExtUtils::Constant; 1}) {
"\t$missing\n" ;
}
- push @names, {name => 'ZLIB_VERSION', type => 'PV' };
+ push @names, { name => 'ZLIB_VERSION', type => 'PV' };
+
+ push @names, map { { name => $_,
+ macro => version_Macro $verSpecificNames{$_}
+ }
+ }
+ keys %verSpecificNames ;
ExtUtils::Constant::WriteConstants(
NAME => 'Zlib',
@@ -162,6 +180,7 @@ if (eval {require ExtUtils::Constant; 1}) {
XS_FILE => 'constants.xs',
);
+
}
else {
foreach my $name (qw( constants.h constants.xs ))