diff options
author | Diego 'Flameeyes' Pettenò <flameeyes@gmail.com> | 2006-07-08 15:10:22 +0000 |
---|---|---|
committer | Diego 'Flameeyes' Pettenò <flameeyes@gmail.com> | 2006-07-08 15:10:22 +0000 |
commit | 01fbf505d5e096490818d48c998613b4ff5e4ddb (patch) | |
tree | 926a88ef5b107fa2ff8b5e8726be9f063718abdb | |
parent | 184d4aa860486558ca346acf5a7f0d3b9ba20bca (diff) | |
download | xine-lib-01fbf505d5e096490818d48c998613b4ff5e4ddb.tar.gz xine-lib-01fbf505d5e096490818d48c998613b4ff5e4ddb.tar.bz2 |
Build VIS support for ffmpeg only if is enabled. When enabling VIS and user didn't give any mcpu argument, default to v9 to allow building (GCC defaults to v8 up to 4.1 series).
CVS patchset: 8097
CVS date: 2006/07/08 15:10:22
-rw-r--r-- | configure.ac | 21 | ||||
-rw-r--r-- | src/libffmpeg/libavcodec/sparc/Makefile.am | 2 |
2 files changed, 16 insertions, 7 deletions
diff --git a/configure.ac b/configure.ac index bd8ac15ae..4fa002269 100644 --- a/configure.ac +++ b/configure.ac @@ -375,9 +375,7 @@ AC_ARG_ENABLE(altivec, enable_altivec=yes) AC_ARG_ENABLE(vis, - AC_HELP_STRING([--disable-vis], [do not use assembly codes for Sun UltraSPARC CPUs]), - enable_vis=$enableval, - enable_vis=yes) + AC_HELP_STRING([--disable-vis], [do not use assembly codes for Sun UltraSPARC CPUs])) AC_ARG_ENABLE(mlib, AC_HELP_STRING([--disable-mlib], [do not build Sun mediaLib support]), @@ -2018,8 +2016,8 @@ case "$host_or_hostalias" in fi ;; sparc*-*-linux*) - if test x$enable_vis = xyes; then - AC_DEFINE_UNQUOTED(ENABLE_VIS,,[Define this if you have Sun UltraSPARC CPU]) + if test x$enable_vis != xno; then + has_vis=yes fi AC_DEFINE_UNQUOTED(FPM_SPARC,,[Define to select libmad fixed point arithmetic implementation]) @@ -2030,8 +2028,8 @@ case "$host_or_hostalias" in case `$CC --version 2>/dev/null` in 1.*|2.*) ;; *) - if test x$enable_vis = xyes; then - AC_DEFINE_UNQUOTED(ENABLE_VIS,,[Define this if you have Sun UltraSPARC CPU]) + if test x$enable_vis != xno; then + has_vis=yes fi ;; esac @@ -2059,6 +2057,15 @@ esac AM_CONDITIONAL(HOST_OS_DARWIN, test x"$HOST_OS_DARWIN" = "x1") +if test "x$has_vis" = "xyes"; then + AC_DEFINE_UNQUOTED(ENABLE_VIS,,[Define this if you have Sun UltraSPARC CPU]) + case $CFLAGS in + *-mcpu=*) ;; + *) CFLAGS="$CFLAGS -mcpu=v9" ;; + esac +fi +AM_CONDITIONAL(ENABLE_VIS, test x"$has_vis" = "xyes") + AM_CONDITIONAL(HAVE_FFMMX, test x"$enable_ffmmx" = "xyes") dnl --------------------------------------------- diff --git a/src/libffmpeg/libavcodec/sparc/Makefile.am b/src/libffmpeg/libavcodec/sparc/Makefile.am index f52b0c10b..4f464e682 100644 --- a/src/libffmpeg/libavcodec/sparc/Makefile.am +++ b/src/libffmpeg/libavcodec/sparc/Makefile.am @@ -11,6 +11,8 @@ libavcodec_sparc_dummy = libavcodec_sparc_dummy.c EXTRA_DIST = $(libavcodec_sparc_src) $(libavcodec_sparc_dummy) vis.h +if ENABLE_VIS sparc_modules = $(libavcodec_sparc_src) +endif libavcodec_sparc_la_SOURCES = $(sparc_modules) $(libavcodec_sparc_dummy) |