gtk+_2.24.25: backport a fix for building with newer host perl

This backports a patch from gtk+ upstream to prevent an issue when
building on Fedora 23 hosts.

(From OE-Core rev: fd27f8620ae4d95dfe07b27eee4256b0a128348a)

Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Joshua Lock 2016-05-05 13:33:21 +01:00 committed by Richard Purdie
parent 3a4d269d39
commit 9b9b8285be
2 changed files with 76 additions and 0 deletions

View File

@ -0,0 +1,75 @@
From 3da748930fdcb19aaae32ae2fc6cb2d802857752 Mon Sep 17 00:00:00 2001
From: Matthias Clasen <mclasen@redhat.com>
Date: Fri, 1 Feb 2013 21:58:34 -0500
Subject: Avoid perl warnings
Apparently, defined is not cool anymore.
Upstream-status: Backport [2.24.28+]
Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
---
demos/gtk-demo/geninclude.pl.in | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/demos/gtk-demo/geninclude.pl.in b/demos/gtk-demo/geninclude.pl.in
index b41e926..02b5c97 100755
--- a/demos/gtk-demo/geninclude.pl.in
+++ b/demos/gtk-demo/geninclude.pl.in
@@ -40,7 +40,7 @@ foreach $href (@demos) {
my $do_next = 0;
# parent detected
- if (defined @parents) {
+ if (@parents) {
foreach $foo (@parents) {
if ($foo eq $parent_name) {
$do_next = 1;
@@ -54,7 +54,7 @@ foreach $href (@demos) {
push @parents, $parent_name;
- $tmp = (defined @child_arrays)?($#child_arrays + 1):0;
+ $tmp = (@child_arrays)?($#child_arrays + 1):0;
push @child_arrays, "child$tmp";
push @demos, {"title" => $parent_name, "file" => "NULL",
@@ -62,7 +62,7 @@ foreach $href (@demos) {
}
}
-if (defined @parents) {
+if (@parents) {
$i = 0;
for ($i = 0; $i <= $#parents; $i++) {
$first = 1;
@@ -73,7 +73,7 @@ if (defined @parents) {
for ($j = 0; $j <= $#demos; $j++) {
$href = $demos[$j];
- if (!defined $demos[$j]) {
+ if (!$demos[$j]) {
next;
}
@@ -105,7 +105,7 @@ if (defined @parents) {
} @demos_old;
# sort the child arrays
-if (defined @child_arrays) {
+if (@child_arrays) {
for ($i = 0; $i <= $#child_arrays; $i++) {
@foo_old = @{$child_arrays[$i]};
@@ -133,7 +133,7 @@ foreach $href (@demos) {
print ", \n";
}
- if (defined @parents) {
+ if (@parents) {
for ($i = 0; $i <= $#parents; $i++) {
if ($parents[$i] eq $href->{title}) {
--
cgit v0.12

View File

@ -9,6 +9,7 @@ SRC_URI = "http://ftp.gnome.org/pub/gnome/sources/gtk+/2.24/gtk+-${PV}.tar.xz \
file://hardcoded_libtool.patch \
file://toggle-font.diff;striplevel=0 \
file://doc-fixes.patch \
file://Avoid-perl-warnings.patch \
"
SRC_URI[md5sum] = "612350704dd3aacb95355a4981930c6f"