summaryrefslogtreecommitdiff
path: root/ffmpeg
diff options
context:
space:
mode:
Diffstat (limited to 'ffmpeg')
-rw-r--r--ffmpeg/0001-libavutil-clean-up-unused-FF_SYMVER-macro.patch55
-rw-r--r--ffmpeg/APKBUILD173
2 files changed, 228 insertions, 0 deletions
diff --git a/ffmpeg/0001-libavutil-clean-up-unused-FF_SYMVER-macro.patch b/ffmpeg/0001-libavutil-clean-up-unused-FF_SYMVER-macro.patch
new file mode 100644
index 0000000..9cc6fdf
--- /dev/null
+++ b/ffmpeg/0001-libavutil-clean-up-unused-FF_SYMVER-macro.patch
@@ -0,0 +1,55 @@
+From ab11be0becb90542f10d5713659b559842c53af2 Mon Sep 17 00:00:00 2001
+From: Natanael Copa <ncopa@alpinelinux.org>
+Date: Tue, 29 Mar 2016 15:15:17 +0200
+Subject: [PATCH] libavutil: clean up unused FF_SYMVER macro
+
+There is nothing using it since commit d63443b9 (lavc: drop the
+av_fast_{re,m}alloc compatibility wrappers).
+
+Signed-off-by: Natanael Copa <ncopa@alpinelinux.org>
+---
+ libavutil/internal.h | 28 ----------------------------
+ 1 file changed, 28 deletions(-)
+
+diff --git a/libavutil/internal.h b/libavutil/internal.h
+index 61784b5..69d63d5 100644
+--- a/libavutil/internal.h
++++ b/libavutil/internal.h
+@@ -187,34 +187,6 @@
+ #endif
+
+ /**
+- * Define a function with only the non-default version specified.
+- *
+- * On systems with ELF shared libraries, all symbols exported from
+- * FFmpeg libraries are tagged with the name and major version of the
+- * library to which they belong. If a function is moved from one
+- * library to another, a wrapper must be retained in the original
+- * location to preserve binary compatibility.
+- *
+- * Functions defined with this macro will never be used to resolve
+- * symbols by the build-time linker.
+- *
+- * @param type return type of function
+- * @param name name of function
+- * @param args argument list of function
+- * @param ver version tag to assign function
+- */
+-#if HAVE_SYMVER_ASM_LABEL
+-# define FF_SYMVER(type, name, args, ver) \
+- type ff_##name args __asm__ (EXTERN_PREFIX #name "@" ver); \
+- type ff_##name args
+-#elif HAVE_SYMVER_GNU_ASM
+-# define FF_SYMVER(type, name, args, ver) \
+- __asm__ (".symver ff_" #name "," EXTERN_PREFIX #name "@" ver); \
+- type ff_##name args; \
+- type ff_##name args
+-#endif
+-
+-/**
+ * Return NULL if a threading library has not been enabled.
+ * Used to disable threading functions in AVCodec definitions
+ * when not needed.
+--
+2.7.4
+
diff --git a/ffmpeg/APKBUILD b/ffmpeg/APKBUILD
new file mode 100644
index 0000000..1d545ec
--- /dev/null
+++ b/ffmpeg/APKBUILD
@@ -0,0 +1,173 @@
+# Contributor: Sergei Lukin <sergej.lukin@gmail.com>
+# Contributor: Ɓukasz Jendrysik <scadu@yandex.com>
+# Contributor: Jakub Skrzypnik <j.skrzypnik@openmailbox.org>
+# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
+pkgname=ffmpeg
+pkgver=4.2.2
+pkgrel=0
+pkgdesc="Complete and free Internet live audio and video broadcasting solution for Linux/Unix"
+url="https://ffmpeg.org/"
+arch="all"
+license="GPL-2.0-or-later AND LGPL-2.1-or-later"
+options="!check" # tests/data/hls-lists.append.m3u8 fails
+subpackages="$pkgname-dev $pkgname-doc $pkgname-libs"
+makedepends="
+ alsa-lib-dev
+ coreutils
+ bzip2-dev
+ gnutls-dev
+ imlib2-dev
+ lame-dev
+ libass-dev
+ libssh-dev
+ libtheora-dev
+ libva-dev
+ libvdpau-dev
+ libvorbis-dev
+ libvpx-dev
+ libxfixes-dev
+ opus-dev
+ perl-dev
+ sdl2-dev
+ v4l-utils-dev
+ x264-dev
+ x265-dev
+ xvidcore-dev
+ yasm
+ zlib-dev
+ "
+checkdepends="rsync"
+source="https://ffmpeg.org/releases/ffmpeg-$pkgver.tar.xz
+ 0001-libavutil-clean-up-unused-FF_SYMVER-macro.patch
+ "
+
+# secfixes:
+# 4.1.4-r0:
+# - CVE-2019-12730
+# 4.1.3-r0:
+# - CVE-2019-9718
+# - CVE-2019-9721
+# - CVE-2019-11338
+# - CVE-2019-11339
+# 4.1.1-r0:
+# - CVE-2019-1000016
+# 4.1-r0:
+# - CVE-2018-13305
+# - CVE-2018-15822
+# 4.0.2-r0:
+# - CVE-2018-13301
+# - CVE-2018-13303
+# - CVE-2018-13304
+# - CVE-2018-1999010
+# - CVE-2018-1999011
+# - CVE-2018-1999012
+# - CVE-2018-1999013
+# - CVE-2018-1999014
+# - CVE-2018-1999015
+# 4.0.1-r0:
+# - CVE-2018-12459
+# - CVE-2018-12460
+# 4.0.0-r0:
+# - CVE-2018-6912
+# - CVE-2018-7757
+# - CVE-2018-9841
+# 3.4.4-r0:
+# - CVE-2018-14395
+# 3.4.3-r0:
+# - CVE-2018-7557
+# - CVE-2018-7751
+# - CVE-2018-10001
+# - CVE-2018-12458
+# - CVE-2018-13300
+# - CVE-2018-13302
+# - CVE-2018-14394
+# 3.3.4-r0:
+# - CVE-2017-14054
+# - CVE-2017-14055
+# - CVE-2017-14056
+# - CVE-2017-14057
+# - CVE-2017-14058
+# - CVE-2017-14059
+# - CVE-2017-14169
+# - CVE-2017-14170
+# - CVE-2017-14171
+# - CVE-2017-14222
+# - CVE-2017-14223
+# - CVE-2017-14225
+
+# add support for AV1 codec for all archies except armhf and armv7
+# as aom is not available on them
+_aom="";
+
+case "$CARCH" in
+ x86|x86_64|aarch64|ppc64le|s390x )
+ _aom="--enable-libaom"; makedepends="$makedepends aom-dev" ;;
+esac
+
+build() {
+ local _dbg="--disable-debug"
+ local _asm=""
+ [ -n "$DEBUG" ] && _dbg="--enable-debug"
+
+ case "$CARCH" in
+ x86) _arch_opts="--disable-asm" ;;
+ arm*) _arch_opts="--enable-omx --enable-omx-rpi --enable-mmal" ;;
+ esac
+
+ ./configure \
+ --prefix=/usr \
+ --enable-avresample \
+ --enable-avfilter \
+ --enable-gnutls \
+ --enable-gpl \
+ --enable-libass \
+ --enable-libmp3lame \
+ --enable-libvorbis \
+ --enable-libvpx \
+ --enable-libxvid \
+ --enable-libx264 \
+ --enable-libx265 \
+ --enable-libtheora \
+ --enable-libv4l2 \
+ --enable-postproc \
+ --enable-pic \
+ --enable-pthreads \
+ --enable-shared \
+ --enable-libxcb \
+ --enable-libssh \
+ --disable-stripping \
+ --disable-static \
+ --disable-librtmp \
+ --enable-vaapi \
+ --enable-vdpau \
+ --enable-libopus \
+ $_arch_opts $_aom $_dbg
+ make
+ ${CC:-gcc} -o tools/qt-faststart $CFLAGS tools/qt-faststart.c
+ make doc/ffmpeg.1 doc/ffplay.1
+}
+
+# https://ffmpeg.org/fate.html
+check() {
+ ./configure \
+ --samples=fate-suite/
+ make fate-rsync
+ make fate-list
+ make fate
+}
+
+package() {
+ make DESTDIR="$pkgdir" install install-man
+ install -D -m755 tools/qt-faststart "$pkgdir/usr/bin/qt-faststart"
+# strip --strip-debug "$pkgdir"/usr/lib/*.a
+}
+
+libs() {
+ pkgdesc="Libraries for ffmpeg"
+ replaces="ffmpeg"
+ mkdir -p "$subpkgdir"/usr
+ mv "$pkgdir"/usr/lib "$subpkgdir"/usr
+}
+
+sha512sums="381cd6732fa699eb89000621cf34256920596ed1f9de3c2194dbad35fdf2165269eb7d3a147a0eb75dc18fbb6d601382b5801750e09fc63547766842f84208e3 ffmpeg-4.2.2.tar.xz
+1047a23eda51b576ac200d5106a1cd318d1d5291643b3a69e025c0a7b6f3dbc9f6eb0e1e6faa231b7e38c8dd4e49a54f7431f87a93664da35825cc2e9e8aedf4 0001-libavutil-clean-up-unused-FF_SYMVER-macro.patch"