Commit 6bc0215f authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

contrib: add libvpx

parent 3593c1e8
......@@ -10,6 +10,7 @@ FFMPEGCONF = \
--disable-doc \
--disable-decoder=libvpx \
--enable-libgsm \
--enable-libvpx \
--disable-debug \
--enable-gpl \
--enable-postproc \
......@@ -21,7 +22,7 @@ FFMPEGCONF = \
--disable-protocols \
--disable-avfilter \
--disable-network
DEPS_ffmpeg = zlib gsm
DEPS_ffmpeg = zlib gsm vpx $(DEPS_vpx)
# Optional dependencies
ifdef BUILD_ENCODERS
......@@ -33,9 +34,6 @@ FFMPEGCONF += --disable-encoders --disable-muxers
# XXX: REVISIT --enable-small ?
endif
#FFMPEGCONF += --enable-libvpx
#DEPS_ffmpeg += vpx $(DEPS_vpx)
# XXX: REVISIT
#ifndef HAVE_FPU
#FFMPEGCONF += --disable-mpegaudio-hp
......
5608a095c96c40bdf9538901c52dd68a1b33767cbc52d9f7c5f9e0b74147f85c31f9a940be827d01f28eaf6bb495f55e920b93edc61cacbaa067ab7aed918aa3 libvpx-v0.9.6.tar.bz2
diff -Nru libvpx.orig/build/make/configure.sh libvpx/build/make/configure.sh
--- libvpx.orig/build/make/configure.sh 2011-07-04 19:21:14.000000000 +0300
+++ libvpx/build/make/configure.sh 2011-07-04 19:22:10.000000000 +0300
@@ -659,8 +659,8 @@
check_add_asflags -mcpu=${tgt_isa}
elif enabled armv7
then
- check_add_cflags -march=armv7-a -mcpu=cortex-a8 -mfpu=neon -mfloat-abi=softfp #-ftree-vectorize
- check_add_asflags -mcpu=cortex-a8 -mfpu=neon -mfloat-abi=softfp #-march=armv7-a
+ check_add_cflags -march=armv7-a -mcpu=cortex-a8 -mfpu=neon #-ftree-vectorize
+ check_add_asflags -mcpu=cortex-a8 -mfpu=neon #-march=armv7-a
else
check_add_cflags -march=${tgt_isa}
check_add_asflags -march=${tgt_isa}
diff -Nru libvpx.orig/build/make/configure.sh libvpx/build/make/configure.sh
--- libvpx.orig/build/make/configure.sh 2011-07-04 19:18:07.000000000 +0300
+++ libvpx/build/make/configure.sh 2011-07-04 19:19:08.000000000 +0300
@@ -648,14 +648,6 @@
case ${tgt_cc} in
gcc)
- if enabled iwmmxt || enabled iwmmxt2
- then
- CROSS=${CROSS:-arm-iwmmxt-linux-gnueabi-}
- elif enabled symbian; then
- CROSS=${CROSS:-arm-none-symbianelf-}
- else
- CROSS=${CROSS:-arm-none-linux-gnueabi-}
- fi
link_with_cc=gcc
setup_gnu_toolchain
arch_int=${tgt_isa##armv}
@@ -806,7 +798,6 @@
esac
;;
mips*)
- CROSS=${CROSS:-mipsel-linux-uclibc-}
link_with_cc=gcc
setup_gnu_toolchain
tune_cflags="-mtune="
@@ -855,7 +846,6 @@
solaris*)
CC=${CC:-${CROSS}gcc}
LD=${LD:-${CROSS}gcc}
- CROSS=${CROSS:-g}
;;
esac
# libvpx
VPX_VERSION := v0.9.6
VPX_URL := http://webm.googlecode.com/files/libvpx-$(VPX_VERSION).tar.bz2
$(TARBALLS)/libvpx-$(VPX_VERSION).tar.bz2:
$(call download,$(VPX_URL))
.sum-vpx: libvpx-$(VPX_VERSION).tar.bz2
libvpx: libvpx-$(VPX_VERSION).tar.bz2 .sum-vpx
$(UNPACK)
$(APPLY) $(SRC)/vpx/libvpx-no-cross.patch
$(APPLY) $(SRC)/vpx/libvpx-no-abi.patch
$(MOVE)
DEPS_vpx =
ifdef HAVE_CROSS_COMPILE
VPX_CROSS := $(HOST)-
else
VPX_CROSS :=
endif
ifeq ($(ARCH),arm)
VPX_ARCH := armv7$(warning ARM architecture version 7 assumed)
else ifeq ($(ARCH),i386)
VPX_ARCH := x86
#DEPS_vpx += yasm $(DEPS_yasm)
else ifeq ($(ARCH),mips)
VPX_ARCH := mips32
else ifeq ($(ARCH),ppc)
VPX_ARCH := ppc32
else ifeq ($(ARCH),ppc64)
VPX_ARCH := ppc64
else ifeq ($(ARCH),sparc)
VPX_ARCH := sparch
else ifeq ($(ARCH),x86_64)
VPX_ARCH := x86_64
#DEPS_vpx += yasm $(DEPS_yasm)
endif
ifdef HAVE_LINUX
VPX_OS := linux
else ifdef HAVE_MACOSX
ifeq ($(ARCH),arm)
VPX_OS := darwin
else
VPX_OS := darwin9
endif
else ifdef HAVE_SOLARIS
VPX_OS := solaris
else ifdef HAVE_WIN64 # must be before WIN32
VPX_OS := win64
else ifdef HAVE_WIN32
VPX_OS := win32
endif
VPX_TARGET := generic-gnu
ifdef VPX_ARCH
ifdef VPX_OS
VPX_TARGET := $(VPX_ARCH)-$(VPX_OS)-gcc
endif
endif
.vpx: libvpx
env
cd $< && CROSS=$(VPX_CROSS) ./configure --target=$(VPX_TARGET) \
--disable-install-bins \
--disable-install-srcs \
--disable-install-libs \
--disable-install-docs \
--disable-examples \
--disable-vp8-decoder
cd $< && $(MAKE) install
rm -Rf -- "$(PREFIX)/include/vpx/"
mkdir -p -- "$(PREFIX)/include/vpx/"
# Of course! Why the hell would it be listed or in make install?
cp $</vpx/*.h $</vpx_ports/*.h "$(PREFIX)/include/vpx"
rm -f -- "$(PREFIX)/include/vpx/config.h"
$(RANLIB) $</libvpx.a
# Of course! Why the hell would it be listed or in make install?
install -D -- $</libvpx.a "$(PREFIX)/lib/libvpx.a"
touch $@
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment