[libyuv] Fix building on EL-5

Peter Lemenkov peter at fedoraproject.org
Thu Jan 12 12:22:21 UTC 2012


commit deec1356cef0124258cbbc9574231ccc03b53ff1
Author: Peter Lemenkov <lemenkov at gmail.com>
Date:   Thu Jan 12 16:22:11 2012 +0400

    Fix building on EL-5
    
    Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>

 .gitignore                                  |    1 +
 libyuv-0001-Initial-autotools-support.patch |   52 +++++++++++++++++++-------
 libyuv.spec                                 |    9 +++--
 sources                                     |    2 +-
 4 files changed, 46 insertions(+), 18 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index fe01dbe..f8e4170 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1 +1,2 @@
 /libyuv-0.tar.xz
+/libyuv-0.tar.bz2
diff --git a/libyuv-0001-Initial-autotools-support.patch b/libyuv-0001-Initial-autotools-support.patch
index 9efd80d..f3e2731 100644
--- a/libyuv-0001-Initial-autotools-support.patch
+++ b/libyuv-0001-Initial-autotools-support.patch
@@ -1,4 +1,4 @@
-From ee51477cdedf2126af866064ff627cb3fe652ce7 Mon Sep 17 00:00:00 2001
+From cfe42adec008210eecff7429ce1dacdd8f5ca1d7 Mon Sep 17 00:00:00 2001
 From: Peter Lemenkov <lemenkov at gmail.com>
 Date: Fri, 16 Dec 2011 22:08:41 +0400
 Subject: [PATCH 1/1] Initial autotools support
@@ -6,12 +6,12 @@ Subject: [PATCH 1/1] Initial autotools support
 Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>
 ---
  Makefile.am           |    1 +
- autogen.sh            |    9 ++++++
- configure.ac          |   67 +++++++++++++++++++++++++++++++++++++++++++++++++
- source/Makefile.am    |   47 ++++++++++++++++++++++++++++++++++
- source/libyuv.pc.in   |    9 ++++++
- unit_test/Makefile.am |   20 ++++++++++++++
- 6 files changed, 153 insertions(+), 0 deletions(-)
+ autogen.sh            |    9 +++++
+ configure.ac          |   91 +++++++++++++++++++++++++++++++++++++++++++++++++
+ source/Makefile.am    |   47 +++++++++++++++++++++++++
+ source/libyuv.pc.in   |    9 +++++
+ unit_test/Makefile.am |   20 +++++++++++
+ 6 files changed, 177 insertions(+), 0 deletions(-)
  create mode 100644 Makefile.am
  create mode 100755 autogen.sh
  create mode 100644 configure.ac
@@ -43,15 +43,15 @@ index 0000000..14988f2
 +./configure ${@}
 diff --git a/configure.ac b/configure.ac
 new file mode 100644
-index 0000000..140866a
+index 0000000..1b4cd8b
 --- /dev/null
 +++ b/configure.ac
-@@ -0,0 +1,67 @@
+@@ -0,0 +1,91 @@
 +AC_INIT([libyuv], [0], [http://groups.google.com/group/discuss-libyuv], [libyuv], [http://code.google.com/p/libyuv/])
 +
 +AC_CANONICAL_TARGET
 +
-+AM_INIT_AUTOMAKE([dist-xz tar-ustar])
++AM_INIT_AUTOMAKE([dist-bzip2 tar-ustar])
 +
 +AC_SUBST(LIBYUV_VERSION_INFO, [0:0:0])
 +
@@ -76,6 +76,29 @@ index 0000000..140866a
 +		;;
 +esac
 +
++AC_ARG_ENABLE(
++	      neon,
++	      [  --enable-neon           enable ARM NEON support],
++	      [
++	       AC_MSG_CHECKING(for NEON in current arch/CFLAGS)
++	       AC_LINK_IFELSE([
++			       AC_LANG_PROGRAM(
++					       [[
++						#include <arm_neon.h>
++						int32x4_t testfunc(int16_t *a, int16_t *b)
++						{
++							return vmull_s16(vld1_s16(a), vld1_s16(b));
++						}
++						]]
++					       )
++			       ],
++			       [has_neon=yes],
++			       [has_neon=no]
++			      )
++	       AC_MSG_RESULT($has_neon)
++	      ]
++	     )
++
 +AC_ARG_WITH([test],
 +	    AC_HELP_STRING([--with-test],[enable test suite.]),
 +	    [with_test="$withval"],[with_test="no"]
@@ -112,11 +135,12 @@ index 0000000..140866a
 +AM_CONDITIONAL(LIBYUV_WINDOWS, test "$windows" = "yes")
 +
 +AM_CONDITIONAL(WITH_TEST, test "$with_test" = "yes")
++AM_CONDITIONAL(ENABLE_NEON, test "$has_neon" = "yes")
 +
 +AC_OUTPUT
 diff --git a/source/Makefile.am b/source/Makefile.am
 new file mode 100644
-index 0000000..bbec8d4
+index 0000000..6382066
 --- /dev/null
 +++ b/source/Makefile.am
 @@ -0,0 +1,47 @@
@@ -147,9 +171,9 @@ index 0000000..bbec8d4
 +windows_SOURCES = row_win.cc
 +endif
 +
-+#if ANDROID_NEON
-+#neon_SOURCES = rotate_neon.cc row_neon.cc
-+#endif
++if ENABLE_NEON
++neon_SOURCES = rotate_neon.cc row_neon.cc
++endif
 +
 +libyuv_la_SOURCES = compare.cc \
 +		    convert.cc \
diff --git a/libyuv.spec b/libyuv.spec
index 4f54e64..b42a143 100644
--- a/libyuv.spec
+++ b/libyuv.spec
@@ -1,13 +1,13 @@
 Name:		libyuv
 Summary:	YUV conversion and scaling functionality library
 Version:	0
-Release:	0.2.20120109svn128%{?dist}
+Release:	0.3.20120109svn128%{?dist}
 License:	BSD
 Group:		Development/Libraries
 Url:		http://code.google.com/p/libyuv/
 ## svn -r 128 export http://libyuv.googlecode.com/svn/trunk libyuv-0
-## tar -cJvf libyuv-0.tar.xz libyuv-0
-Source0:	%{name}-%{version}.tar.xz
+## tar -cjvf libyuv-0.tar.bz2 libyuv-0
+Source0:	%{name}-%{version}.tar.bz2
 Patch1:		libyuv-0001-Initial-autotools-support.patch
 BuildRequires:	autoconf
 BuildRequires:	automake
@@ -79,6 +79,9 @@ make check
 
 
 %changelog
+* Thu Jan 12 2012 Peter Lemenkov <lemenkov at gmail.com> - 0-0.3.20120109svn128
+- Use bzip2 instead of xz (for EL-5)
+
 * Wed Jan 11 2012 Peter Lemenkov <lemenkov at gmail.com> - 0-0.2.20120109svn128
 - Update to svn rev. 128
 - Enable unit-tests
diff --git a/sources b/sources
index 39d2c5b..5670e51 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-e813a5055290e300fb03e0201844d2c6  libyuv-0.tar.xz
+477386e026bb4efcf940ed442ec98058  libyuv-0.tar.bz2


More information about the scm-commits mailing list