[awstats/f16] fix for perl-5.14 (#768443,#768982,#771031)
plautrba
plautrba at fedoraproject.org
Mon Jan 2 12:19:56 UTC 2012
commit a9364d5d3388bf6778fa09ca284e3cf278767029
Author: Petr Lautrbach <plautrba at redhat.com>
Date: Mon Jan 2 13:04:03 2012 +0100
fix for perl-5.14 (#768443,#768982,#771031)
awstats-perl-5.14.patch | 24 ++++++++++++++++++++++++
awstats.spec | 2 ++
2 files changed, 26 insertions(+), 0 deletions(-)
---
diff --git a/awstats-perl-5.14.patch b/awstats-perl-5.14.patch
new file mode 100644
index 0000000..b8cc7bf
--- /dev/null
+++ b/awstats-perl-5.14.patch
@@ -0,0 +1,24 @@
+diff --git a/wwwroot/cgi-bin/awstats.pl b/wwwroot/cgi-bin/awstats.pl
+index bae9db6..b13a525 100755
+--- a/wwwroot/cgi-bin/awstats.pl
++++ b/wwwroot/cgi-bin/awstats.pl
+@@ -1353,9 +1353,7 @@ sub debug {
+ #------------------------------------------------------------------------------
+ sub OptimizeArray {
+ my $array = shift;
+- my @arrayunreg = map {
+- if (/\(\?[-\w]*:(.*)\)/) { $1 }
+- } @$array;
++ my @arrayunreg = map { qr/$_/ } @$array;
+ my $notcasesensitive = shift;
+ my $searchlist = 0;
+ if ($Debug) {
+@@ -7809,7 +7807,7 @@ sub DecodeEncodedString {
+ # Return: standardregex
+ #------------------------------------------------------------------------------
+ sub UnCompileRegex {
+- shift =~ /\(\?[-\w]*:(.*)\)/;
++ shift =~ /\(\?[-\^\w]*:(.*)\)/;
+ return $1;
+ }
+
diff --git a/awstats.spec b/awstats.spec
index 591e4f4..5146b28 100644
--- a/awstats.spec
+++ b/awstats.spec
@@ -7,6 +7,7 @@ Group: Applications/Internet
URL: http://awstats.sourceforge.net
Source0: http://downloads.sourceforge.net/project/awstats/AWStats/%{version}/awstats-%{version}.tar.gz
Patch0: awstats-awredir.pl-sanitize-parameters.patch
+Patch2: awstats-perl-5.14.patch
BuildArch: noarch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
@@ -40,6 +41,7 @@ http://localhost/awstats/awstats.pl
%prep
%setup -q
%patch0 -p 1
+%patch2 -p 1
# Fix style sheets.
perl -pi -e 's,/icon,/awstatsicons,g' wwwroot/css/*
# Fix some bad file permissions here for convenience.
More information about the scm-commits
mailing list