[packages/php/PHP_5_4] fix build with libvpx 1.4.0

glen glen at pld-linux.org
Sun May 24 17:40:25 CEST 2015


commit f7322ca773eecb917d5acfd03775a842fc67580d
Author: Elan Ruusamäe <glen at delfi.ee>
Date:   Sun May 24 18:36:13 2015 +0300

    fix build with libvpx 1.4.0

 libvpx2.patch | 41 +++++++++++++++++++++++++++++++++++++++++
 php.spec      |  2 ++
 2 files changed, 43 insertions(+)
---
diff --git a/php.spec b/php.spec
index 051eba6..4befbc1 100644
--- a/php.spec
+++ b/php.spec
@@ -215,6 +215,7 @@ Patch65:	system-libzip.patch
 Patch66:	php-db.patch
 Patch67:	mysql-lib-ver-mismatch.patch
 Patch68:	x32.patch
+Patch70:	libvpx2.patch
 URL:		http://www.php.net/
 %{?with_interbase:%{!?with_interbase_inst:BuildRequires:	Firebird-devel >= 1.0.2.908-2}}
 %{?with_pspell:BuildRequires:	aspell-devel >= 2:0.50.0}
@@ -1938,6 +1939,7 @@ cp -p php.ini-production php.ini
 %{?with_system_libzip:%patch65 -p1}
 %patch66 -p1
 %patch67 -p1
+%patch70 -p1
 
 sed -i -e '/PHP_ADD_LIBRARY_WITH_PATH/s#xmlrpc,#xmlrpc-epi,#' ext/xmlrpc/config.m4
 
diff --git a/libvpx2.patch b/libvpx2.patch
new file mode 100644
index 0000000..9f0bd9f
--- /dev/null
+++ b/libvpx2.patch
@@ -0,0 +1,41 @@
+Fix build with latest libvpx 1.4.0
+These new constants exist at least since 1.0.0
+Compatibility ones have been droped in 1.4.0
+
+https://github.com/libgd/libgd/commit/d41eb72cd4545c394578332e5c102dee69e02ee8
+
+From d242f958dfca03640356ea29f624005a895f64a0 Mon Sep 17 00:00:00 2001
+From: Ole Markus With <olemarkus at olemarkus.org>
+Date: Sun, 24 May 2015 09:19:09 +0200
+Subject: [PATCH] Fix for bug #69479: GD fails to build with newer libvpx
+
+---
+ ext/gd/libgd/webpimg.c | 14 +++++++-------
+ 1 file changed, 7 insertions(+), 7 deletions(-)
+
+diff --git a/ext/gd/libgd/webpimg.c b/ext/gd/libgd/webpimg.c
+index 1f1c023..9d801a2 100644
+--- a/ext/gd/libgd/webpimg.c
++++ b/ext/gd/libgd/webpimg.c
+@@ -706,14 +706,14 @@ static WebPResult VPXEncode(const uint8* Y,
+     codec_ctl(&enc, VP8E_SET_STATIC_THRESHOLD, 0);
+     codec_ctl(&enc, VP8E_SET_TOKEN_PARTITIONS, 2);
+ 
+-    vpx_img_wrap(&img, IMG_FMT_I420,
++    vpx_img_wrap(&img, VPX_IMG_FMT_I420,
+                  y_width, y_height, 16, (uint8*)(Y));
+-    img.planes[PLANE_Y] = (uint8*)(Y);
+-    img.planes[PLANE_U] = (uint8*)(U);
+-    img.planes[PLANE_V] = (uint8*)(V);
+-    img.stride[PLANE_Y] = y_stride;
+-    img.stride[PLANE_U] = uv_stride;
+-    img.stride[PLANE_V] = uv_stride;
++    img.planes[VPX_PLANE_Y] = (uint8*)(Y);
++    img.planes[VPX_PLANE_U] = (uint8*)(U);
++    img.planes[VPX_PLANE_V] = (uint8*)(V);
++    img.stride[VPX_PLANE_Y] = y_stride;
++    img.stride[VPX_PLANE_U] = uv_stride;
++    img.stride[VPX_PLANE_V] = uv_stride;
+ 
+     res = vpx_codec_encode(&enc, &img, 0, 1, 0, VPX_DL_BEST_QUALITY);
+ 
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/php.git/commitdiff/f7322ca773eecb917d5acfd03775a842fc67580d



More information about the pld-cvs-commit mailing list