ffmpeg: drop 2.6 & 2.7, bump to 2.8.7 & 3.0.2, minor fixes. (WIP) (#579)

* Drop 2.6.3 & 2.7.2, bump 2.8.6 to 2.8.7 and 3.0.1 to 3.0.2.
* ffmpeg, ffprobe and ffserver were being shipped in secondary arch
  builds (due to rm $binDir instead of rm $prefix/bin where they were
  being installed) but did not have a cmd: in PROVIDES. Fixed this by
  moving these to a _bin subpackage on x86_gcc2 using 2nd arch x86.
* Fix CONFLICTS_devel in 3.0.2 (missing "_legacy"),
* Add ffmpeg2_bin to CONFLICTS in 3.0.2.
* Add ffmpeg and ffmpeg_legacy to CONFLICTS_bin in 2.8.7.
* Reorder some sections.
* Switch all HOMEPAGE and SOURCE_URI to https.
* Switch from tar.bz2 to tar.xz for 2.8.7.
* 2.8.7 and 3.0.2 build OK (on x86_gcc2 using x86 as 2nd arch) but
  "make check" fails with "runtime_loader: Cannot open file
  libavutil.so.55: No such file or directory". Failure happens on
  TEST api-threadmessage for 3.0.2 and on TEST api-flac for 2.8.7.
This commit is contained in:
fbrosson
2016-05-06 23:14:05 +00:00
committed by waddlesplash
parent 76dae26944
commit 82fc2e5458
6 changed files with 48 additions and 373 deletions

View File

@@ -2,18 +2,19 @@ SUMMARY="Audio and video recording, conversion, and streaming library"
DESCRIPTION="FFmpeg is a complete, cross-platform solution to record, convert \
and stream audio and video. It includes libavcodec - the leading audio/video \
codec library."
HOMEPAGE="http://www.ffmpeg.org"
LICENSE="GNU LGPL v2.1
GNU GPL v2"
HOMEPAGE="https://ffmpeg.org/"
COPYRIGHT="2000-2003 Fabrice Bellard
2003-2016 the FFmpeg developers"
SOURCE_URI="http://ffmpeg.org/releases/ffmpeg-$portVersion.tar.xz"
CHECKSUM_SHA256="c389ca5e3c29e758dd82ee6981130fe79e73b06e26db1a3aa971daea63598bc1"
LICENSE="GNU LGPL v2.1
GNU GPL v2"
REVISION="1"
ARCHITECTURES="!x86_gcc2 x86 x86_64"
SECONDARY_ARCHITECTURES="x86"
SOURCE_URI="https://ffmpeg.org/releases/ffmpeg-$portVersion.tar.xz"
CHECKSUM_SHA256="82943cc7b0c4d14b612404de0dd7b24cd8ca3511d51e4fd3ae36b2d71bb95223"
PATCHES="ffmpeg-$portVersion.patchset"
ARCHITECTURES="!x86_gcc2 x86 x86_64"
SECONDARY_ARCHITECTURES="!x86_gcc2 x86"
PROVIDES="
ffmpeg$secondaryArchSuffix = $portVersion compat >= 3.0
cmd:ffmpeg = $portVersion compat >= 3.0
@@ -45,6 +46,7 @@ REQUIRES="
"
CONFLICTS="
ffmpeg_legacy$secondaryArchSuffix
ffmpeg2${secondaryArchSuffix}_bin
"
PROVIDES_devel="
@@ -64,7 +66,8 @@ REQUIRES_devel="
devel:libspeex$secondaryArchSuffix
"
CONFLICTS_devel="
ffmpeg${secondaryArchSuffix}_devel
ffmpeg_legacy${secondaryArchSuffix}_devel
ffmpeg2${secondaryArchSuffix}_devel
"
BUILD_REQUIRES="
@@ -82,6 +85,7 @@ BUILD_PREREQUIRES="
cmd:gcc$secondaryArchSuffix >= 5
cmd:ld$secondaryArchSuffix
cmd:awk
cmd:cmp
cmd:grep
cmd:make
cmd:perl
@@ -89,7 +93,6 @@ BUILD_PREREQUIRES="
cmd:sed
cmd:texi2html
cmd:yasm
cmd:cmp
"
GLOBAL_WRITABLE_FILES="

View File

@@ -1,173 +0,0 @@
SUMMARY="Audio and video recording, conversion, and streaming library"
DESCRIPTION="FFmpeg is a complete, cross-platform solution to record, convert \
and stream audio and video. It includes libavcodec - the leading audio/video \
codec library."
HOMEPAGE="http://www.ffmpeg.org"
LICENSE="GNU LGPL v2.1
GNU GPL v2"
COPYRIGHT="2000-2003 Fabrice Bellard
2003-2015 the FFmpeg developers"
SOURCE_URI="http://www.ffmpeg.org/releases/ffmpeg-$portVersion.tar.bz2"
CHECKSUM_SHA256="59eb98c1b5896ac29abc0385f7c875d1b4942d695818818d418ee71eea1e0cfb"
SOURCE_DIR="ffmpeg-$portVersion"
REVISION="1"
ARCHITECTURES="!x86_gcc2 x86 x86_64"
SECONDARY_ARCHITECTURES="x86"
PROVIDES="
ffmpeg2$secondaryArchSuffix = $portVersion compat >= 2.6
lib:libavutil$secondaryArchSuffix = 54.20.100 compat >= 54
lib:libavcodec$secondaryArchSuffix = 56.26.100 compat >= 56
lib:libavformat$secondaryArchSuffix = 56.25.101 compat >= 56
lib:libavdevice$secondaryArchSuffix = 56.4.100 compat >= 56
lib:libavfilter$secondaryArchSuffix = 5.11.102 compat >= 5
lib:libavresample$secondaryArchSuffix = 2.1.0 compat >= 2
lib:libswscale$secondaryArchSuffix = 3.1.101 compat >= 3
lib:libswresample$secondaryArchSuffix = 1.1.100 compat >= 1
lib:libpostproc$secondaryArchSuffix = 53.3.100 compat >= 53
"
REQUIRES="
haiku$secondaryArchSuffix
lib:libbz2$secondaryArchSuffix
lib:libogg$secondaryArchSuffix
lib:libspeex$secondaryArchSuffix
lib:libtheoradec$secondaryArchSuffix
lib:libtheoraenc$secondaryArchSuffix
lib:libvorbis$secondaryArchSuffix
lib:libvorbisenc$secondaryArchSuffix
lib:libvpx$secondaryArchSuffix
lib:libz$secondaryArchSuffix
"
CONFLICTS="
ffmpeg_legacy$secondaryArchSuffix
"
PROVIDES_devel="
ffmpeg2${secondaryArchSuffix}_devel = $portVersion compat >= 2.4
devel:libavutil$secondaryArchSuffix = 54.20.100 compat >= 54
devel:libavcodec$secondaryArchSuffix = 56.26.100 compat >= 56
devel:libavformat$secondaryArchSuffix = 56.25.101 compat >= 56
devel:libavdevice$secondaryArchSuffix = 56.4.100 compat >= 56
devel:libavfilter$secondaryArchSuffix = 5.11.102 compat >= 5
devel:libavresample$secondaryArchSuffix = 2.1.0 compat >= 2
devel:libswscale$secondaryArchSuffix = 3.1.101 compat >= 3
devel:libswresample$secondaryArchSuffix = 1.1.100 compat >= 1
devel:libpostproc$secondaryArchSuffix = 53.3.100 compat >= 53
"
REQUIRES_devel="
ffmpeg2$secondaryArchSuffix == $portVersion base
devel:libspeex$secondaryArchSuffix
"
CONFLICTS_devel="
ffmpeg_legacy${secondaryArchSuffix}_devel
ffmpeg${secondaryArchSuffix}_devel
"
BUILD_REQUIRES="
devel:libbz2$secondaryArchSuffix
devel:libogg$secondaryArchSuffix
devel:libspeex$secondaryArchSuffix
devel:libtheora$secondaryArchSuffix
devel:libvorbis$secondaryArchSuffix
devel:libvpx$secondaryArchSuffix
devel:libz$secondaryArchSuffix
"
BUILD_PREREQUIRES="
haiku${secondaryArchSuffix}_devel
cmd:gcc$secondaryArchSuffix
cmd:ld$secondaryArchSuffix
cmd:awk
cmd:grep
cmd:make
cmd:perl
cmd:pkg_config$secondaryArchSuffix
cmd:sed
cmd:texi2html
cmd:yasm
"
GLOBAL_WRITABLE_FILES="
settings/ffserver.conf
"
PATCH()
{
# patch hard-coded config file path
sed -i "s,/etc/ffserver.conf,$sysconfDir/ffserver.conf," \
ffserver.c \
doc/ffserver.texi
# patch hard-coded paths to perl
sed -i "s,/usr/bin/perl,$portPackageLinksDir/cmd~perl/bin/perl," \
doc/Doxyfile \
doc/texi2pod.pl
}
BUILD()
{
# not an autotools configure
./configure \
--prefix=$prefix \
--bindir=$prefix/bin \
--datadir=$dataDir/$portName \
--incdir=$includeDir \
--libdir=$libDir \
--shlibdir=$libDir \
--mandir=$manDir \
--disable-debug \
--enable-shared \
--enable-libvorbis \
--enable-libspeex \
--enable-libtheora \
--enable-libvpx \
--enable-gpl \
--enable-avresample \
--progs-suffix=-26
if [ $targetArchitecture = x86_64 ]; then
cflags="-fPIC -std=c99"
else
cflags="-fno-PIC -std=c99"
fi
make $jobArgs CFLAGS="$cflags"
}
INSTALL()
{
make install
prepareInstalledDevelLibs \
libavcodec \
libavdevice \
libavfilter \
libavformat \
libavresample \
libavutil \
libswresample \
libswscale \
libpostproc
fixPkgconfig
# The pkgconfig file reference other libraries using the wrong paths, which
# creates a lot of confusion. Fix them so correct paths are used.
local develPackageName="${portName}_devel-$portFullVersion"
local packageLinksDir=$(dirname $portPackageLinksDir)
local linksDir="$packageLinksDir/${develPackageName}/devel~libspeex$secondaryArchSuffix/$relativeDevelopLibDir"
sed -i -e "s,^\(Libs.private.*\)-L.*speex.* \(-lspeex.*\),\1-L$linksDir \2," \
$developLibDir/pkgconfig/libavcodec.pc \
$developLibDir/pkgconfig/libavdevice.pc \
$developLibDir/pkgconfig/libavfilter.pc \
$developLibDir/pkgconfig/libavformat.pc
rm -rf $prefix/share $binDir $manDir $dataDir
# devel package
packageEntries devel \
$developDir
}
TEST()
{
make check
}

View File

@@ -1,175 +0,0 @@
SUMMARY="Audio and video recording, conversion, and streaming library"
DESCRIPTION="FFmpeg is a complete, cross-platform solution to record, convert \
and stream audio and video. It includes libavcodec - the leading audio/video \
codec library."
HOMEPAGE="http://www.ffmpeg.org"
LICENSE="GNU LGPL v2.1
GNU GPL v2"
COPYRIGHT="2000-2003 Fabrice Bellard
2003-2015 the FFmpeg developers"
SOURCE_URI="http://www.ffmpeg.org/releases/ffmpeg-$portVersion.tar.bz2"
CHECKSUM_SHA256="7ceb7550ad628c526fa6c9ff23fdfb687a62f54d90c4a730998d8c2b417b9ef2"
SOURCE_DIR="ffmpeg-$portVersion"
REVISION="1"
ARCHITECTURES="!x86_gcc2 x86 x86_64"
SECONDARY_ARCHITECTURES="x86"
PROVIDES="
ffmpeg2$secondaryArchSuffix = $portVersion compat >= 2.7
lib:libavutil$secondaryArchSuffix = 54.27.100 compat >= 54
lib:libavcodec$secondaryArchSuffix = 56.41.100 compat >= 56
lib:libavformat$secondaryArchSuffix = 56.36.100 compat >= 56
lib:libavdevice$secondaryArchSuffix = 56.4.100 compat >= 56
lib:libavfilter$secondaryArchSuffix = 5.16.101 compat >= 5
lib:libavresample$secondaryArchSuffix = 2.1.0 compat >= 2
lib:libswscale$secondaryArchSuffix = 3.1.101 compat >= 3
lib:libswresample$secondaryArchSuffix = 1.2.100 compat >= 1
lib:libpostproc$secondaryArchSuffix = 53.3.100 compat >= 53
"
REQUIRES="
haiku$secondaryArchSuffix
lib:libbz2$secondaryArchSuffix
lib:libogg$secondaryArchSuffix
lib:libspeex$secondaryArchSuffix
lib:libmodplug$secondaryArchSuffix
lib:libtheoradec$secondaryArchSuffix
lib:libtheoraenc$secondaryArchSuffix
lib:libvorbis$secondaryArchSuffix
lib:libvorbisenc$secondaryArchSuffix
lib:libvpx$secondaryArchSuffix
lib:libz$secondaryArchSuffix
"
CONFLICTS="
ffmpeg_legacy$secondaryArchSuffix
"
PROVIDES_devel="
ffmpeg2${secondaryArchSuffix}_devel = $portVersion compat >= 2.4
devel:libavutil$secondaryArchSuffix = 54.27.100 compat >= 54
devel:libavcodec$secondaryArchSuffix = 56.51.100 compat >= 56
devel:libavformat$secondaryArchSuffix = 56.36.100 compat >= 56
devel:libavdevice$secondaryArchSuffix = 56.4.100 compat >= 56
devel:libavfilter$secondaryArchSuffix = 5.16.101 compat >= 5
devel:libavresample$secondaryArchSuffix = 2.1.0 compat >= 2
devel:libswscale$secondaryArchSuffix = 3.1.101 compat >= 3
devel:libswresample$secondaryArchSuffix = 1.2.100 compat >= 1
devel:libpostproc$secondaryArchSuffix = 53.3.100 compat >= 53
"
REQUIRES_devel="
ffmpeg2$secondaryArchSuffix == $portVersion base
devel:libspeex$secondaryArchSuffix
"
CONFLICTS_devel="
ffmpeg_legacy${secondaryArchSuffix}_devel
ffmpeg${secondaryArchSuffix}_devel
"
BUILD_REQUIRES="
devel:libbz2$secondaryArchSuffix
devel:libmodplug$secondaryArchSuffix
devel:libogg$secondaryArchSuffix
devel:libspeex$secondaryArchSuffix
devel:libtheora$secondaryArchSuffix
devel:libvorbis$secondaryArchSuffix
devel:libvpx$secondaryArchSuffix
devel:libz$secondaryArchSuffix
"
BUILD_PREREQUIRES="
haiku${secondaryArchSuffix}_devel
cmd:gcc$secondaryArchSuffix
cmd:ld$secondaryArchSuffix
cmd:awk
cmd:grep
cmd:make
cmd:perl
cmd:pkg_config$secondaryArchSuffix
cmd:sed
cmd:texi2html
cmd:yasm
"
GLOBAL_WRITABLE_FILES="
settings/ffserver.conf
"
PATCH()
{
# patch hard-coded config file path
sed -i "s,/etc/ffserver.conf,$sysconfDir/ffserver.conf," \
ffserver.c \
doc/ffserver.texi
# patch hard-coded paths to perl
sed -i "s,/usr/bin/perl,$portPackageLinksDir/cmd~perl/bin/perl," \
doc/Doxyfile \
doc/texi2pod.pl
}
BUILD()
{
# not an autotools configure
./configure \
--prefix=$prefix \
--bindir=$prefix/bin \
--datadir=$dataDir/$portName \
--incdir=$includeDir \
--libdir=$libDir \
--shlibdir=$libDir \
--mandir=$manDir \
--disable-debug \
--enable-shared \
--enable-libmodplug \
--enable-libvorbis \
--enable-libspeex \
--enable-libtheora \
--enable-libvpx \
--enable-gpl \
--enable-avresample
if [ $targetArchitecture = x86_64 ]; then
cflags="-fPIC -std=c99"
else
cflags="-fno-PIC -std=c99"
fi
make $jobArgs CFLAGS="$cflags"
}
INSTALL()
{
make install
prepareInstalledDevelLibs \
libavcodec \
libavdevice \
libavfilter \
libavformat \
libavresample \
libavutil \
libswresample \
libswscale \
libpostproc
fixPkgconfig
# The pkgconfig file reference other libraries using the wrong paths, which
# creates a lot of confusion. Fix them so correct paths are used.
local develPackageName="${portName}_devel-$portFullVersion"
local packageLinksDir=$(dirname $portPackageLinksDir)
local linksDir="$packageLinksDir/${develPackageName}/devel~libspeex$secondaryArchSuffix/$relativeDevelopLibDir"
sed -i -e "s,^\(Libs.private.*\)-L.*speex.* \(-lspeex.*\),\1-L$linksDir \2," \
$developLibDir/pkgconfig/libavcodec.pc \
$developLibDir/pkgconfig/libavdevice.pc \
$developLibDir/pkgconfig/libavfilter.pc \
$developLibDir/pkgconfig/libavformat.pc
rm -rf $prefix/share $binDir $manDir $dataDir
# devel package
packageEntries devel \
$developDir
}
TEST()
{
make check
}

View File

@@ -2,19 +2,20 @@ SUMMARY="Audio and video recording, conversion, and streaming library"
DESCRIPTION="FFmpeg is a complete, cross-platform solution to record, convert \
and stream audio and video. It includes libavcodec - the leading audio/video \
codec library."
HOMEPAGE="http://www.ffmpeg.org"
LICENSE="GNU LGPL v2.1
GNU GPL v2"
HOMEPAGE="https://ffmpeg.org/"
COPYRIGHT="2000-2003 Fabrice Bellard
2003-2016 the FFmpeg developers"
SOURCE_URI="http://www.ffmpeg.org/releases/ffmpeg-$portVersion.tar.bz2"
CHECKSUM_SHA256="40611e329bc354592c6f8f1deb033c31b91f80e91f5707ca4f9afceca78d8e62"
SOURCE_DIR="ffmpeg-$portVersion"
LICENSE="GNU LGPL v2.1
GNU GPL v2"
REVISION="1"
ARCHITECTURES="!x86_gcc2 x86 x86_64"
SECONDARY_ARCHITECTURES="x86"
SOURCE_URI="https://ffmpeg.org/releases/ffmpeg-$portVersion.tar.xz"
CHECKSUM_SHA256="97be8a6c1cab2c52015544f76d40f6fd0babcb1b40cf601b4e57fb818564157c"
SOURCE_DIR="ffmpeg-$portVersion"
PATCHES="ffmpeg-$portVersion.patchset"
ARCHITECTURES="!x86_gcc2 x86 x86_64"
SECONDARY_ARCHITECTURES="!x86_gcc2 x86"
PROVIDES="
ffmpeg2$secondaryArchSuffix = $portVersion compat >= 2.8
lib:libavutil$secondaryArchSuffix = 54.31.100 compat >= 54
@@ -40,9 +41,6 @@ REQUIRES="
lib:libvpx$secondaryArchSuffix
lib:libz$secondaryArchSuffix
"
CONFLICTS="
ffmpeg_legacy$secondaryArchSuffix
"
PROVIDES_devel="
ffmpeg2${secondaryArchSuffix}_devel = $portVersion compat >= 2.4
@@ -65,6 +63,22 @@ CONFLICTS_devel="
ffmpeg${secondaryArchSuffix}_devel
"
SUMMARY_bin="Command line tools for ffmpeg-2.8.x"
PROVIDES_bin="
ffmpeg2${secondaryArchSuffix}_bin = $portVersion compat >= 2.8
cmd:ffmpeg = $portVersion compat >= 2.8
cmd:ffprobe = $portVersion compat >= 2.8
cmd:ffserver = $portVersion compat >= 2.8
"
REQUIRES_bin="
haiku$secondaryArchSuffix
ffmpeg2$secondaryArchSuffix == $portVersion base
"
CONFLICTS_bin="
ffmpeg_legacy$secondaryArchSuffix
ffmpeg$secondaryArchSuffix
"
BUILD_REQUIRES="
devel:libbz2$secondaryArchSuffix
devel:libmodplug$secondaryArchSuffix
@@ -80,6 +94,7 @@ BUILD_PREREQUIRES="
cmd:gcc$secondaryArchSuffix
cmd:ld$secondaryArchSuffix
cmd:awk
cmd:cmp
cmd:grep
cmd:make
cmd:perl
@@ -87,7 +102,6 @@ BUILD_PREREQUIRES="
cmd:sed
cmd:texi2html
cmd:yasm
cmd:cmp
"
GLOBAL_WRITABLE_FILES="
@@ -164,11 +178,17 @@ INSTALL()
$developLibDir/pkgconfig/libavfilter.pc \
$developLibDir/pkgconfig/libavformat.pc
rm -rf $prefix/share $binDir $manDir $dataDir
rm -rf $prefix/share $dataDir
# bin package
packageEntries bin \
$prefix/bin \
$manDir/man1
# devel package
packageEntries devel \
$developDir
$developDir \
$manDir
}
TEST()

View File

@@ -8,7 +8,7 @@ diff --git a/configure b/configure
index 475c087..5a95b97 100755
--- a/configure
+++ b/configure
@@ -6052,6 +6052,7 @@ enabled threads && ! enabled pthreads && ! enabled atomics_native && die "non pt
@@ -5783,6 +5783,7 @@ enabled threads && ! enabled pthreads && ! enabled atomics_native && die "non pt
if test $target_os = "haiku"; then
disable memalign
disable posix_memalign

View File

@@ -8,7 +8,7 @@ diff --git a/configure b/configure
index 475c087..5a95b97 100755
--- a/configure
+++ b/configure
@@ -6052,6 +6052,7 @@ enabled threads && ! enabled pthreads && ! enabled atomics_native && die "non pt
@@ -6040,6 +6040,7 @@ enabled threads && ! enabled pthreads && ! enabled atomics_native && die "non pt
if test $target_os = "haiku"; then
disable memalign
disable posix_memalign