[x264-devel] ppc: Add VSX support to configure

Luca Barbato git at videolan.org
Thu Dec 1 21:01:44 CET 2016


x264 | branch: master | Luca Barbato <lu_zero at gentoo.org> | Tue Nov  1 23:16:14 2016 +0100| [2b741f81e51f92d053d87a49f59ff1026553a0f6] | committer: Henrik Gramner

ppc: Add VSX support to configure

> http://git.videolan.org/gitweb.cgi/x264.git/?a=commit;h=2b741f81e51f92d053d87a49f59ff1026553a0f6
---

 configure | 16 +++++++++++++++-
 1 file changed, 15 insertions(+), 1 deletion(-)

diff --git a/configure b/configure
index 9d1586c..293d008 100755
--- a/configure
+++ b/configure
@@ -357,6 +357,7 @@ chroma_format="all"
 compiler="GNU"
 compiler_style="GNU"
 opencl="yes"
+vsx="auto"
 
 CFLAGS="$CFLAGS -Wall -I. -I\$(SRCPATH)"
 LDFLAGS="$LDFLAGS"
@@ -375,7 +376,7 @@ NL="
 # list of all preprocessor HAVE values we can define
 CONFIG_HAVE="MALLOC_H ALTIVEC ALTIVEC_H MMX ARMV6 ARMV6T2 NEON BEOSTHREAD POSIXTHREAD WIN32THREAD THREAD LOG2F SWSCALE \
              LAVF FFMS GPAC AVS GPL VECTOREXT INTERLACED CPU_COUNT OPENCL THP LSMASH X86_INLINE_ASM AS_FUNC INTEL_DISPATCHER \
-             MSA MMAP WINRT"
+             MSA MMAP WINRT VSX"
 
 # parse options
 
@@ -474,6 +475,9 @@ for opt do
         --host=*)
             host="$optarg"
             ;;
+        --disable-vsx)
+            vsx="no"
+            ;;
         --disable-opencl)
             opencl="no"
             ;;
@@ -737,6 +741,14 @@ case $host_cpu in
                 CFLAGS="$CFLAGS -maltivec -mabi=altivec"
                 define HAVE_ALTIVEC_H
             fi
+            if [ "$vsx" != "no" ] ; then
+                vsx="no"
+                if cc_check "" "-mvsx" ; then
+                    CFLAGS="$CFLAGS -mvsx"
+                    define HAVE_VSX
+                    vsx="yes"
+                fi
+            fi
         fi
         ;;
     sparc)
@@ -788,6 +800,8 @@ case $host_cpu in
         ;;
 esac
 
+[ "$vsx" != "yes" ] && vsx="no"
+
 if [ $SYS = WINDOWS ]; then
     if ! rc_check "0 RCDATA {0}" ; then
         RC=""



More information about the x264-devel mailing list