Date: Wednesday, December 28, 2016 @ 15:57:28 Author: alucryd Revision: 203202
archrelease: copy trunk to community-i686, community-x86_64 Added: handbrake/repos/community-i686/PKGBUILD (from rev 203201, handbrake/trunk/PKGBUILD) handbrake/repos/community-i686/handbarke-fix-crash-during-2-pass-encode.patch (from rev 203201, handbrake/trunk/handbarke-fix-crash-during-2-pass-encode.patch) handbrake/repos/community-i686/handbrake-fix-2-pass-vp8-and-vp9-encoding.patch (from rev 203201, handbrake/trunk/handbrake-fix-2-pass-vp8-and-vp9-encoding.patch) handbrake/repos/community-i686/handbrake-fix-missing-x265-link-flag.patch (from rev 203201, handbrake/trunk/handbrake-fix-missing-x265-link-flag.patch) handbrake/repos/community-x86_64/PKGBUILD (from rev 203201, handbrake/trunk/PKGBUILD) handbrake/repos/community-x86_64/handbarke-fix-crash-during-2-pass-encode.patch (from rev 203201, handbrake/trunk/handbarke-fix-crash-during-2-pass-encode.patch) handbrake/repos/community-x86_64/handbrake-fix-2-pass-vp8-and-vp9-encoding.patch (from rev 203201, handbrake/trunk/handbrake-fix-2-pass-vp8-and-vp9-encoding.patch) handbrake/repos/community-x86_64/handbrake-fix-missing-x265-link-flag.patch (from rev 203201, handbrake/trunk/handbrake-fix-missing-x265-link-flag.patch) Deleted: handbrake/repos/community-i686/PKGBUILD handbrake/repos/community-i686/handbarke-fix-crash-during-2-pass-encode.patch handbrake/repos/community-i686/handbrake-fix-2-pass-vp8-and-vp9-encoding.patch handbrake/repos/community-i686/handbrake-fix-missing-x265-link-flag.patch handbrake/repos/community-x86_64/PKGBUILD handbrake/repos/community-x86_64/handbarke-fix-crash-during-2-pass-encode.patch handbrake/repos/community-x86_64/handbrake-fix-2-pass-vp8-and-vp9-encoding.patch handbrake/repos/community-x86_64/handbrake-fix-missing-x265-link-flag.patch ------------------------------------------------------------------+ /PKGBUILD | 158 ++++++++++ /handbarke-fix-crash-during-2-pass-encode.patch | 54 +++ /handbrake-fix-2-pass-vp8-and-vp9-encoding.patch | 62 +++ /handbrake-fix-missing-x265-link-flag.patch | 26 + community-i686/PKGBUILD | 79 ----- community-i686/handbarke-fix-crash-during-2-pass-encode.patch | 27 - community-i686/handbrake-fix-2-pass-vp8-and-vp9-encoding.patch | 31 - community-i686/handbrake-fix-missing-x265-link-flag.patch | 13 community-x86_64/PKGBUILD | 79 ----- community-x86_64/handbarke-fix-crash-during-2-pass-encode.patch | 27 - community-x86_64/handbrake-fix-2-pass-vp8-and-vp9-encoding.patch | 31 - community-x86_64/handbrake-fix-missing-x265-link-flag.patch | 13 12 files changed, 300 insertions(+), 300 deletions(-) Deleted: community-i686/PKGBUILD =================================================================== --- community-i686/PKGBUILD 2016-12-28 15:57:14 UTC (rev 203201) +++ community-i686/PKGBUILD 2016-12-28 15:57:28 UTC (rev 203202) @@ -1,79 +0,0 @@ -# $Id$ -# Maintainer: Evangelos Foutras <evange...@foutrelis.com> -# Contributor: Giovanni Scafora <giova...@archlinux.org> -# Contributor: Sebastien Piccand <sebcactus gmail com> - -pkgname=('handbrake' 'handbrake-cli') -pkgver=1.0.0 -pkgrel=3 -arch=('i686' 'x86_64') -url="https://handbrake.fr/" -license=('GPL') -makedepends=('intltool' 'python2' 'yasm' 'wget' 'bzip2' 'gcc-libs' 'libnotify' - 'gst-plugins-base' 'gtk3' 'dbus-glib' 'fribidi' 'libass' 'lame' - 'fontconfig' 'freetype2' 'libxml2' 'libogg' 'libvorbis' 'cmake' - 'libtheora' 'libsamplerate' 'ffmpeg' 'x264' 'libx264' 'x265' - 'libvpx' 'libdvdnav' 'jansson' 'librsvg' 'libgudev') -source=(https://handbrake.fr/mirror/HandBrake-$pkgver.tar.bz2 - handbarke-fix-crash-during-2-pass-encode.patch - handbrake-fix-2-pass-vp8-and-vp9-encoding.patch - handbrake-fix-missing-x265-link-flag.patch) -sha256sums=('15fb4593c70d75621212e4499f018c3c93d7ce39f1083bf527d4616ded0044c5' - 'aaa09e9b3dbad54024f02afe8ace5390b281c7cc6aae80cf26d43f773b2d19f7' - '1b6d800acde0cc2c7e6080f23f2ddd435257c5a2d853acdeb4e4a6fada856310' - '05e212e76b6e0b94a04de02cbeb7bf9db607059e19297b5bd3d0d143135285c4') - -prepare() { - cd "$srcdir/HandBrake-$pkgver" - - # https://github.com/HandBrake/HandBrake/commit/e159ab1662ba#commitcomment-20303756 - patch -Np1 -i ../handbarke-fix-crash-during-2-pass-encode.patch - # https://github.com/HandBrake/HandBrake/issues/449#issuecomment-269352579 - patch -Np1 -i ../handbrake-fix-2-pass-vp8-and-vp9-encoding.patch - - # https://bugs.gentoo.org/show_bug.cgi?id=552792 - patch -Np1 -i ../handbrake-fix-missing-x265-link-flag.patch - - # Use more system libs - # Bundled libbluray is kept because it is patched locally - for _lib in ffmpeg x265 libvpx libdvdnav libdvdread; do - sed -i "/MODULES += contrib\/$_lib/d" make/include/main.defs - done -} - -build() { - cd "$srcdir/HandBrake-$pkgver" - - ./configure \ - --prefix=/usr \ - --disable-gtk-update-checks - make -C build -} - -package_handbrake() { - pkgdesc="Multithreaded video transcoder" - depends=('bzip2' 'gcc-libs' 'gst-plugins-base' 'libnotify' 'dbus-glib' - 'fribidi' 'libass' 'lame' 'gtk3' 'fontconfig' 'freetype2' 'libxml2' - 'libogg' 'libvorbis' 'libtheora' 'libsamplerate' 'ffmpeg' 'libx264' - 'x265' 'libvpx' 'libdvdnav' 'jansson' 'librsvg' 'libgudev' - 'desktop-file-utils' 'hicolor-icon-theme') - optdepends=('gst-plugins-good: for video previews' - 'gst-libav: for video previews') - - cd "$srcdir/HandBrake-$pkgver/build" - - make DESTDIR="$pkgdir" install - rm "$pkgdir/usr/bin/HandBrakeCLI" -} - -package_handbrake-cli() { - pkgdesc="Multithreaded video transcoder (CLI)" - depends=('bzip2' 'gcc-libs' 'zlib' 'fribidi' 'libass' 'lame' 'libxml2' - 'libtheora' 'libsamplerate' 'ffmpeg' 'libx264' 'x265' 'libvpx' - 'libdvdnav' 'jansson') - - cd "$srcdir/HandBrake-$pkgver/build" - install -D HandBrakeCLI "$pkgdir/usr/bin/HandBrakeCLI" -} - -# vim:set ts=2 sw=2 et: Copied: handbrake/repos/community-i686/PKGBUILD (from rev 203201, handbrake/trunk/PKGBUILD) =================================================================== --- community-i686/PKGBUILD (rev 0) +++ community-i686/PKGBUILD 2016-12-28 15:57:28 UTC (rev 203202) @@ -0,0 +1,79 @@ +# $Id$ +# Maintainer: Evangelos Foutras <evange...@foutrelis.com> +# Contributor: Giovanni Scafora <giova...@archlinux.org> +# Contributor: Sebastien Piccand <sebcactus gmail com> + +pkgname=('handbrake' 'handbrake-cli') +pkgver=1.0.0 +pkgrel=4 +arch=('i686' 'x86_64') +url="https://handbrake.fr/" +license=('GPL') +makedepends=('intltool' 'python2' 'yasm' 'wget' 'bzip2' 'gcc-libs' 'libnotify' + 'gst-plugins-base' 'gtk3' 'dbus-glib' 'fribidi' 'libass' 'lame' + 'fontconfig' 'freetype2' 'libxml2' 'libogg' 'libvorbis' 'cmake' + 'libtheora' 'libsamplerate' 'ffmpeg' 'x264' 'libx264' 'x265' + 'libvpx' 'libdvdnav' 'jansson' 'librsvg' 'libgudev') +source=(https://handbrake.fr/mirror/HandBrake-$pkgver.tar.bz2 + handbarke-fix-crash-during-2-pass-encode.patch + handbrake-fix-2-pass-vp8-and-vp9-encoding.patch + handbrake-fix-missing-x265-link-flag.patch) +sha256sums=('15fb4593c70d75621212e4499f018c3c93d7ce39f1083bf527d4616ded0044c5' + 'aaa09e9b3dbad54024f02afe8ace5390b281c7cc6aae80cf26d43f773b2d19f7' + '1b6d800acde0cc2c7e6080f23f2ddd435257c5a2d853acdeb4e4a6fada856310' + '05e212e76b6e0b94a04de02cbeb7bf9db607059e19297b5bd3d0d143135285c4') + +prepare() { + cd "$srcdir/HandBrake-$pkgver" + + # https://github.com/HandBrake/HandBrake/commit/e159ab1662ba#commitcomment-20303756 + patch -Np1 -i ../handbarke-fix-crash-during-2-pass-encode.patch + # https://github.com/HandBrake/HandBrake/issues/449#issuecomment-269352579 + patch -Np1 -i ../handbrake-fix-2-pass-vp8-and-vp9-encoding.patch + + # https://bugs.gentoo.org/show_bug.cgi?id=552792 + patch -Np1 -i ../handbrake-fix-missing-x265-link-flag.patch + + # Use more system libs + # Bundled libbluray is kept because it is patched locally + for _lib in ffmpeg x265 libvpx libdvdnav libdvdread; do + sed -i "/MODULES += contrib\/$_lib/d" make/include/main.defs + done +} + +build() { + cd "$srcdir/HandBrake-$pkgver" + + ./configure \ + --prefix=/usr \ + --disable-gtk-update-checks + make -C build +} + +package_handbrake() { + pkgdesc="Multithreaded video transcoder" + depends=('bzip2' 'gcc-libs' 'gst-plugins-base' 'libnotify' 'dbus-glib' + 'fribidi' 'libass' 'lame' 'gtk3' 'fontconfig' 'freetype2' 'libxml2' + 'libogg' 'libvorbis' 'libtheora' 'libsamplerate' 'ffmpeg' 'libx264' + 'x265' 'libvpx' 'libdvdnav' 'jansson' 'librsvg' 'libgudev' + 'desktop-file-utils' 'hicolor-icon-theme') + optdepends=('gst-plugins-good: for video previews' + 'gst-libav: for video previews') + + cd "$srcdir/HandBrake-$pkgver/build" + + make DESTDIR="$pkgdir" install + rm "$pkgdir/usr/bin/HandBrakeCLI" +} + +package_handbrake-cli() { + pkgdesc="Multithreaded video transcoder (CLI)" + depends=('bzip2' 'gcc-libs' 'zlib' 'fribidi' 'libass' 'lame' 'libxml2' + 'libtheora' 'libsamplerate' 'ffmpeg' 'libx264' 'x265' 'libvpx' + 'libdvdnav' 'jansson') + + cd "$srcdir/HandBrake-$pkgver/build" + install -D HandBrakeCLI "$pkgdir/usr/bin/HandBrakeCLI" +} + +# vim:set ts=2 sw=2 et: Deleted: community-i686/handbarke-fix-crash-during-2-pass-encode.patch =================================================================== --- community-i686/handbarke-fix-crash-during-2-pass-encode.patch 2016-12-28 15:57:14 UTC (rev 203201) +++ community-i686/handbarke-fix-crash-during-2-pass-encode.patch 2016-12-28 15:57:28 UTC (rev 203202) @@ -1,27 +0,0 @@ -From 3b9c9a263f7ffa959d56d914c62df18c9567c0db Mon Sep 17 00:00:00 2001 -From: John Stebbins <jstebbins...@gmail.com> -Date: Tue, 27 Dec 2016 08:56:25 -0800 -Subject: [PATCH] encavcodec: fix crash during 2 pass encode - -This affect mpeg4, mpeg2, vp8 and vp9 encoding ---- - libhb/encavcodec.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/libhb/encavcodec.c b/libhb/encavcodec.c -index d7a751e..0543fe4 100644 ---- a/libhb/encavcodec.c -+++ b/libhb/encavcodec.c -@@ -352,10 +352,10 @@ int encavcodecInit( hb_work_object_t * w, hb_job_t * job ) - } - - if (job->pass_id == HB_PASS_ENCODE_1ST && -- pv->context->stats_out != NULL) -+ context->stats_out != NULL) - { - // Some encoders may write stats during init in avcodec_open -- fprintf(pv->file, "%s", pv->context->stats_out); -+ fprintf(pv->file, "%s", context->stats_out); - } - - // avcodec_open populates the opts dictionary with the Copied: handbrake/repos/community-i686/handbarke-fix-crash-during-2-pass-encode.patch (from rev 203201, handbrake/trunk/handbarke-fix-crash-during-2-pass-encode.patch) =================================================================== --- community-i686/handbarke-fix-crash-during-2-pass-encode.patch (rev 0) +++ community-i686/handbarke-fix-crash-during-2-pass-encode.patch 2016-12-28 15:57:28 UTC (rev 203202) @@ -0,0 +1,27 @@ +From 3b9c9a263f7ffa959d56d914c62df18c9567c0db Mon Sep 17 00:00:00 2001 +From: John Stebbins <jstebbins...@gmail.com> +Date: Tue, 27 Dec 2016 08:56:25 -0800 +Subject: [PATCH] encavcodec: fix crash during 2 pass encode + +This affect mpeg4, mpeg2, vp8 and vp9 encoding +--- + libhb/encavcodec.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/libhb/encavcodec.c b/libhb/encavcodec.c +index d7a751e..0543fe4 100644 +--- a/libhb/encavcodec.c ++++ b/libhb/encavcodec.c +@@ -352,10 +352,10 @@ int encavcodecInit( hb_work_object_t * w, hb_job_t * job ) + } + + if (job->pass_id == HB_PASS_ENCODE_1ST && +- pv->context->stats_out != NULL) ++ context->stats_out != NULL) + { + // Some encoders may write stats during init in avcodec_open +- fprintf(pv->file, "%s", pv->context->stats_out); ++ fprintf(pv->file, "%s", context->stats_out); + } + + // avcodec_open populates the opts dictionary with the Deleted: community-i686/handbrake-fix-2-pass-vp8-and-vp9-encoding.patch =================================================================== --- community-i686/handbrake-fix-2-pass-vp8-and-vp9-encoding.patch 2016-12-28 15:57:14 UTC (rev 203201) +++ community-i686/handbrake-fix-2-pass-vp8-and-vp9-encoding.patch 2016-12-28 15:57:28 UTC (rev 203202) @@ -1,31 +0,0 @@ -From d64dba737d0136b58545be33c50db093df1880c1 Mon Sep 17 00:00:00 2001 -From: John Stebbins <jstebbins...@gmail.com> -Date: Tue, 27 Dec 2016 08:57:06 -0800 -Subject: [PATCH] encavcodec: fix 2 pass vp8 and vp9 encoding - -libvpx only supplies the stats upon the final flush of the encoder. So -we must also write stats after final flush. ---- - libhb/encavcodec.c | 9 +++++++++ - 1 file changed, 9 insertions(+) - -diff --git a/libhb/encavcodec.c b/libhb/encavcodec.c -index 0543fe4..591aa4f 100644 ---- a/libhb/encavcodec.c -+++ b/libhb/encavcodec.c -@@ -610,6 +610,15 @@ static void Flush( hb_work_object_t * w, hb_buffer_list_t * list ) - hb_work_private_t * pv = w->private_data; - - avcodec_send_frame(pv->context, NULL); -+ -+ // Write stats -+ // vpx only writes stats at final flush -+ if (pv->job->pass_id == HB_PASS_ENCODE_1ST && -+ pv->context->stats_out != NULL) -+ { -+ fprintf( pv->file, "%s", pv->context->stats_out ); -+ } -+ - get_packets(w, list); - } - Copied: handbrake/repos/community-i686/handbrake-fix-2-pass-vp8-and-vp9-encoding.patch (from rev 203201, handbrake/trunk/handbrake-fix-2-pass-vp8-and-vp9-encoding.patch) =================================================================== --- community-i686/handbrake-fix-2-pass-vp8-and-vp9-encoding.patch (rev 0) +++ community-i686/handbrake-fix-2-pass-vp8-and-vp9-encoding.patch 2016-12-28 15:57:28 UTC (rev 203202) @@ -0,0 +1,31 @@ +From d64dba737d0136b58545be33c50db093df1880c1 Mon Sep 17 00:00:00 2001 +From: John Stebbins <jstebbins...@gmail.com> +Date: Tue, 27 Dec 2016 08:57:06 -0800 +Subject: [PATCH] encavcodec: fix 2 pass vp8 and vp9 encoding + +libvpx only supplies the stats upon the final flush of the encoder. So +we must also write stats after final flush. +--- + libhb/encavcodec.c | 9 +++++++++ + 1 file changed, 9 insertions(+) + +diff --git a/libhb/encavcodec.c b/libhb/encavcodec.c +index 0543fe4..591aa4f 100644 +--- a/libhb/encavcodec.c ++++ b/libhb/encavcodec.c +@@ -610,6 +610,15 @@ static void Flush( hb_work_object_t * w, hb_buffer_list_t * list ) + hb_work_private_t * pv = w->private_data; + + avcodec_send_frame(pv->context, NULL); ++ ++ // Write stats ++ // vpx only writes stats at final flush ++ if (pv->job->pass_id == HB_PASS_ENCODE_1ST && ++ pv->context->stats_out != NULL) ++ { ++ fprintf( pv->file, "%s", pv->context->stats_out ); ++ } ++ + get_packets(w, list); + } + Deleted: community-i686/handbrake-fix-missing-x265-link-flag.patch =================================================================== --- community-i686/handbrake-fix-missing-x265-link-flag.patch 2016-12-28 15:57:14 UTC (rev 203201) +++ community-i686/handbrake-fix-missing-x265-link-flag.patch 2016-12-28 15:57:28 UTC (rev 203202) @@ -1,13 +0,0 @@ -Written by: Peter Foley <pefol...@pefoley.com> -Gentoo Bug: #552792 - ---- a/test/module.defs -+++ b/test/module.defs -@@ -25,6 +25,7 @@ - - ifeq (1,$(FEATURE.x265)) - TEST.GCC.D += USE_X265 -+ TEST.GCC.l += x265 - endif - - TEST.GCC.l += $(foreach m,$(MODULES.NAMES),$($m.OSL.libs)) Copied: handbrake/repos/community-i686/handbrake-fix-missing-x265-link-flag.patch (from rev 203201, handbrake/trunk/handbrake-fix-missing-x265-link-flag.patch) =================================================================== --- community-i686/handbrake-fix-missing-x265-link-flag.patch (rev 0) +++ community-i686/handbrake-fix-missing-x265-link-flag.patch 2016-12-28 15:57:28 UTC (rev 203202) @@ -0,0 +1,13 @@ +Written by: Peter Foley <pefol...@pefoley.com> +Gentoo Bug: #552792 + +--- a/test/module.defs ++++ b/test/module.defs +@@ -25,6 +25,7 @@ + + ifeq (1,$(FEATURE.x265)) + TEST.GCC.D += USE_X265 ++ TEST.GCC.l += x265 + endif + + TEST.GCC.l += $(foreach m,$(MODULES.NAMES),$($m.OSL.libs)) Deleted: community-x86_64/PKGBUILD =================================================================== --- community-x86_64/PKGBUILD 2016-12-28 15:57:14 UTC (rev 203201) +++ community-x86_64/PKGBUILD 2016-12-28 15:57:28 UTC (rev 203202) @@ -1,79 +0,0 @@ -# $Id$ -# Maintainer: Evangelos Foutras <evange...@foutrelis.com> -# Contributor: Giovanni Scafora <giova...@archlinux.org> -# Contributor: Sebastien Piccand <sebcactus gmail com> - -pkgname=('handbrake' 'handbrake-cli') -pkgver=1.0.0 -pkgrel=3 -arch=('i686' 'x86_64') -url="https://handbrake.fr/" -license=('GPL') -makedepends=('intltool' 'python2' 'yasm' 'wget' 'bzip2' 'gcc-libs' 'libnotify' - 'gst-plugins-base' 'gtk3' 'dbus-glib' 'fribidi' 'libass' 'lame' - 'fontconfig' 'freetype2' 'libxml2' 'libogg' 'libvorbis' 'cmake' - 'libtheora' 'libsamplerate' 'ffmpeg' 'x264' 'libx264' 'x265' - 'libvpx' 'libdvdnav' 'jansson' 'librsvg' 'libgudev') -source=(https://handbrake.fr/mirror/HandBrake-$pkgver.tar.bz2 - handbarke-fix-crash-during-2-pass-encode.patch - handbrake-fix-2-pass-vp8-and-vp9-encoding.patch - handbrake-fix-missing-x265-link-flag.patch) -sha256sums=('15fb4593c70d75621212e4499f018c3c93d7ce39f1083bf527d4616ded0044c5' - 'aaa09e9b3dbad54024f02afe8ace5390b281c7cc6aae80cf26d43f773b2d19f7' - '1b6d800acde0cc2c7e6080f23f2ddd435257c5a2d853acdeb4e4a6fada856310' - '05e212e76b6e0b94a04de02cbeb7bf9db607059e19297b5bd3d0d143135285c4') - -prepare() { - cd "$srcdir/HandBrake-$pkgver" - - # https://github.com/HandBrake/HandBrake/commit/e159ab1662ba#commitcomment-20303756 - patch -Np1 -i ../handbarke-fix-crash-during-2-pass-encode.patch - # https://github.com/HandBrake/HandBrake/issues/449#issuecomment-269352579 - patch -Np1 -i ../handbrake-fix-2-pass-vp8-and-vp9-encoding.patch - - # https://bugs.gentoo.org/show_bug.cgi?id=552792 - patch -Np1 -i ../handbrake-fix-missing-x265-link-flag.patch - - # Use more system libs - # Bundled libbluray is kept because it is patched locally - for _lib in ffmpeg x265 libvpx libdvdnav libdvdread; do - sed -i "/MODULES += contrib\/$_lib/d" make/include/main.defs - done -} - -build() { - cd "$srcdir/HandBrake-$pkgver" - - ./configure \ - --prefix=/usr \ - --disable-gtk-update-checks - make -C build -} - -package_handbrake() { - pkgdesc="Multithreaded video transcoder" - depends=('bzip2' 'gcc-libs' 'gst-plugins-base' 'libnotify' 'dbus-glib' - 'fribidi' 'libass' 'lame' 'gtk3' 'fontconfig' 'freetype2' 'libxml2' - 'libogg' 'libvorbis' 'libtheora' 'libsamplerate' 'ffmpeg' 'libx264' - 'x265' 'libvpx' 'libdvdnav' 'jansson' 'librsvg' 'libgudev' - 'desktop-file-utils' 'hicolor-icon-theme') - optdepends=('gst-plugins-good: for video previews' - 'gst-libav: for video previews') - - cd "$srcdir/HandBrake-$pkgver/build" - - make DESTDIR="$pkgdir" install - rm "$pkgdir/usr/bin/HandBrakeCLI" -} - -package_handbrake-cli() { - pkgdesc="Multithreaded video transcoder (CLI)" - depends=('bzip2' 'gcc-libs' 'zlib' 'fribidi' 'libass' 'lame' 'libxml2' - 'libtheora' 'libsamplerate' 'ffmpeg' 'libx264' 'x265' 'libvpx' - 'libdvdnav' 'jansson') - - cd "$srcdir/HandBrake-$pkgver/build" - install -D HandBrakeCLI "$pkgdir/usr/bin/HandBrakeCLI" -} - -# vim:set ts=2 sw=2 et: Copied: handbrake/repos/community-x86_64/PKGBUILD (from rev 203201, handbrake/trunk/PKGBUILD) =================================================================== --- community-x86_64/PKGBUILD (rev 0) +++ community-x86_64/PKGBUILD 2016-12-28 15:57:28 UTC (rev 203202) @@ -0,0 +1,79 @@ +# $Id$ +# Maintainer: Evangelos Foutras <evange...@foutrelis.com> +# Contributor: Giovanni Scafora <giova...@archlinux.org> +# Contributor: Sebastien Piccand <sebcactus gmail com> + +pkgname=('handbrake' 'handbrake-cli') +pkgver=1.0.0 +pkgrel=4 +arch=('i686' 'x86_64') +url="https://handbrake.fr/" +license=('GPL') +makedepends=('intltool' 'python2' 'yasm' 'wget' 'bzip2' 'gcc-libs' 'libnotify' + 'gst-plugins-base' 'gtk3' 'dbus-glib' 'fribidi' 'libass' 'lame' + 'fontconfig' 'freetype2' 'libxml2' 'libogg' 'libvorbis' 'cmake' + 'libtheora' 'libsamplerate' 'ffmpeg' 'x264' 'libx264' 'x265' + 'libvpx' 'libdvdnav' 'jansson' 'librsvg' 'libgudev') +source=(https://handbrake.fr/mirror/HandBrake-$pkgver.tar.bz2 + handbarke-fix-crash-during-2-pass-encode.patch + handbrake-fix-2-pass-vp8-and-vp9-encoding.patch + handbrake-fix-missing-x265-link-flag.patch) +sha256sums=('15fb4593c70d75621212e4499f018c3c93d7ce39f1083bf527d4616ded0044c5' + 'aaa09e9b3dbad54024f02afe8ace5390b281c7cc6aae80cf26d43f773b2d19f7' + '1b6d800acde0cc2c7e6080f23f2ddd435257c5a2d853acdeb4e4a6fada856310' + '05e212e76b6e0b94a04de02cbeb7bf9db607059e19297b5bd3d0d143135285c4') + +prepare() { + cd "$srcdir/HandBrake-$pkgver" + + # https://github.com/HandBrake/HandBrake/commit/e159ab1662ba#commitcomment-20303756 + patch -Np1 -i ../handbarke-fix-crash-during-2-pass-encode.patch + # https://github.com/HandBrake/HandBrake/issues/449#issuecomment-269352579 + patch -Np1 -i ../handbrake-fix-2-pass-vp8-and-vp9-encoding.patch + + # https://bugs.gentoo.org/show_bug.cgi?id=552792 + patch -Np1 -i ../handbrake-fix-missing-x265-link-flag.patch + + # Use more system libs + # Bundled libbluray is kept because it is patched locally + for _lib in ffmpeg x265 libvpx libdvdnav libdvdread; do + sed -i "/MODULES += contrib\/$_lib/d" make/include/main.defs + done +} + +build() { + cd "$srcdir/HandBrake-$pkgver" + + ./configure \ + --prefix=/usr \ + --disable-gtk-update-checks + make -C build +} + +package_handbrake() { + pkgdesc="Multithreaded video transcoder" + depends=('bzip2' 'gcc-libs' 'gst-plugins-base' 'libnotify' 'dbus-glib' + 'fribidi' 'libass' 'lame' 'gtk3' 'fontconfig' 'freetype2' 'libxml2' + 'libogg' 'libvorbis' 'libtheora' 'libsamplerate' 'ffmpeg' 'libx264' + 'x265' 'libvpx' 'libdvdnav' 'jansson' 'librsvg' 'libgudev' + 'desktop-file-utils' 'hicolor-icon-theme') + optdepends=('gst-plugins-good: for video previews' + 'gst-libav: for video previews') + + cd "$srcdir/HandBrake-$pkgver/build" + + make DESTDIR="$pkgdir" install + rm "$pkgdir/usr/bin/HandBrakeCLI" +} + +package_handbrake-cli() { + pkgdesc="Multithreaded video transcoder (CLI)" + depends=('bzip2' 'gcc-libs' 'zlib' 'fribidi' 'libass' 'lame' 'libxml2' + 'libtheora' 'libsamplerate' 'ffmpeg' 'libx264' 'x265' 'libvpx' + 'libdvdnav' 'jansson') + + cd "$srcdir/HandBrake-$pkgver/build" + install -D HandBrakeCLI "$pkgdir/usr/bin/HandBrakeCLI" +} + +# vim:set ts=2 sw=2 et: Deleted: community-x86_64/handbarke-fix-crash-during-2-pass-encode.patch =================================================================== --- community-x86_64/handbarke-fix-crash-during-2-pass-encode.patch 2016-12-28 15:57:14 UTC (rev 203201) +++ community-x86_64/handbarke-fix-crash-during-2-pass-encode.patch 2016-12-28 15:57:28 UTC (rev 203202) @@ -1,27 +0,0 @@ -From 3b9c9a263f7ffa959d56d914c62df18c9567c0db Mon Sep 17 00:00:00 2001 -From: John Stebbins <jstebbins...@gmail.com> -Date: Tue, 27 Dec 2016 08:56:25 -0800 -Subject: [PATCH] encavcodec: fix crash during 2 pass encode - -This affect mpeg4, mpeg2, vp8 and vp9 encoding ---- - libhb/encavcodec.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/libhb/encavcodec.c b/libhb/encavcodec.c -index d7a751e..0543fe4 100644 ---- a/libhb/encavcodec.c -+++ b/libhb/encavcodec.c -@@ -352,10 +352,10 @@ int encavcodecInit( hb_work_object_t * w, hb_job_t * job ) - } - - if (job->pass_id == HB_PASS_ENCODE_1ST && -- pv->context->stats_out != NULL) -+ context->stats_out != NULL) - { - // Some encoders may write stats during init in avcodec_open -- fprintf(pv->file, "%s", pv->context->stats_out); -+ fprintf(pv->file, "%s", context->stats_out); - } - - // avcodec_open populates the opts dictionary with the Copied: handbrake/repos/community-x86_64/handbarke-fix-crash-during-2-pass-encode.patch (from rev 203201, handbrake/trunk/handbarke-fix-crash-during-2-pass-encode.patch) =================================================================== --- community-x86_64/handbarke-fix-crash-during-2-pass-encode.patch (rev 0) +++ community-x86_64/handbarke-fix-crash-during-2-pass-encode.patch 2016-12-28 15:57:28 UTC (rev 203202) @@ -0,0 +1,27 @@ +From 3b9c9a263f7ffa959d56d914c62df18c9567c0db Mon Sep 17 00:00:00 2001 +From: John Stebbins <jstebbins...@gmail.com> +Date: Tue, 27 Dec 2016 08:56:25 -0800 +Subject: [PATCH] encavcodec: fix crash during 2 pass encode + +This affect mpeg4, mpeg2, vp8 and vp9 encoding +--- + libhb/encavcodec.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/libhb/encavcodec.c b/libhb/encavcodec.c +index d7a751e..0543fe4 100644 +--- a/libhb/encavcodec.c ++++ b/libhb/encavcodec.c +@@ -352,10 +352,10 @@ int encavcodecInit( hb_work_object_t * w, hb_job_t * job ) + } + + if (job->pass_id == HB_PASS_ENCODE_1ST && +- pv->context->stats_out != NULL) ++ context->stats_out != NULL) + { + // Some encoders may write stats during init in avcodec_open +- fprintf(pv->file, "%s", pv->context->stats_out); ++ fprintf(pv->file, "%s", context->stats_out); + } + + // avcodec_open populates the opts dictionary with the Deleted: community-x86_64/handbrake-fix-2-pass-vp8-and-vp9-encoding.patch =================================================================== --- community-x86_64/handbrake-fix-2-pass-vp8-and-vp9-encoding.patch 2016-12-28 15:57:14 UTC (rev 203201) +++ community-x86_64/handbrake-fix-2-pass-vp8-and-vp9-encoding.patch 2016-12-28 15:57:28 UTC (rev 203202) @@ -1,31 +0,0 @@ -From d64dba737d0136b58545be33c50db093df1880c1 Mon Sep 17 00:00:00 2001 -From: John Stebbins <jstebbins...@gmail.com> -Date: Tue, 27 Dec 2016 08:57:06 -0800 -Subject: [PATCH] encavcodec: fix 2 pass vp8 and vp9 encoding - -libvpx only supplies the stats upon the final flush of the encoder. So -we must also write stats after final flush. ---- - libhb/encavcodec.c | 9 +++++++++ - 1 file changed, 9 insertions(+) - -diff --git a/libhb/encavcodec.c b/libhb/encavcodec.c -index 0543fe4..591aa4f 100644 ---- a/libhb/encavcodec.c -+++ b/libhb/encavcodec.c -@@ -610,6 +610,15 @@ static void Flush( hb_work_object_t * w, hb_buffer_list_t * list ) - hb_work_private_t * pv = w->private_data; - - avcodec_send_frame(pv->context, NULL); -+ -+ // Write stats -+ // vpx only writes stats at final flush -+ if (pv->job->pass_id == HB_PASS_ENCODE_1ST && -+ pv->context->stats_out != NULL) -+ { -+ fprintf( pv->file, "%s", pv->context->stats_out ); -+ } -+ - get_packets(w, list); - } - Copied: handbrake/repos/community-x86_64/handbrake-fix-2-pass-vp8-and-vp9-encoding.patch (from rev 203201, handbrake/trunk/handbrake-fix-2-pass-vp8-and-vp9-encoding.patch) =================================================================== --- community-x86_64/handbrake-fix-2-pass-vp8-and-vp9-encoding.patch (rev 0) +++ community-x86_64/handbrake-fix-2-pass-vp8-and-vp9-encoding.patch 2016-12-28 15:57:28 UTC (rev 203202) @@ -0,0 +1,31 @@ +From d64dba737d0136b58545be33c50db093df1880c1 Mon Sep 17 00:00:00 2001 +From: John Stebbins <jstebbins...@gmail.com> +Date: Tue, 27 Dec 2016 08:57:06 -0800 +Subject: [PATCH] encavcodec: fix 2 pass vp8 and vp9 encoding + +libvpx only supplies the stats upon the final flush of the encoder. So +we must also write stats after final flush. +--- + libhb/encavcodec.c | 9 +++++++++ + 1 file changed, 9 insertions(+) + +diff --git a/libhb/encavcodec.c b/libhb/encavcodec.c +index 0543fe4..591aa4f 100644 +--- a/libhb/encavcodec.c ++++ b/libhb/encavcodec.c +@@ -610,6 +610,15 @@ static void Flush( hb_work_object_t * w, hb_buffer_list_t * list ) + hb_work_private_t * pv = w->private_data; + + avcodec_send_frame(pv->context, NULL); ++ ++ // Write stats ++ // vpx only writes stats at final flush ++ if (pv->job->pass_id == HB_PASS_ENCODE_1ST && ++ pv->context->stats_out != NULL) ++ { ++ fprintf( pv->file, "%s", pv->context->stats_out ); ++ } ++ + get_packets(w, list); + } + Deleted: community-x86_64/handbrake-fix-missing-x265-link-flag.patch =================================================================== --- community-x86_64/handbrake-fix-missing-x265-link-flag.patch 2016-12-28 15:57:14 UTC (rev 203201) +++ community-x86_64/handbrake-fix-missing-x265-link-flag.patch 2016-12-28 15:57:28 UTC (rev 203202) @@ -1,13 +0,0 @@ -Written by: Peter Foley <pefol...@pefoley.com> -Gentoo Bug: #552792 - ---- a/test/module.defs -+++ b/test/module.defs -@@ -25,6 +25,7 @@ - - ifeq (1,$(FEATURE.x265)) - TEST.GCC.D += USE_X265 -+ TEST.GCC.l += x265 - endif - - TEST.GCC.l += $(foreach m,$(MODULES.NAMES),$($m.OSL.libs)) Copied: handbrake/repos/community-x86_64/handbrake-fix-missing-x265-link-flag.patch (from rev 203201, handbrake/trunk/handbrake-fix-missing-x265-link-flag.patch) =================================================================== --- community-x86_64/handbrake-fix-missing-x265-link-flag.patch (rev 0) +++ community-x86_64/handbrake-fix-missing-x265-link-flag.patch 2016-12-28 15:57:28 UTC (rev 203202) @@ -0,0 +1,13 @@ +Written by: Peter Foley <pefol...@pefoley.com> +Gentoo Bug: #552792 + +--- a/test/module.defs ++++ b/test/module.defs +@@ -25,6 +25,7 @@ + + ifeq (1,$(FEATURE.x265)) + TEST.GCC.D += USE_X265 ++ TEST.GCC.l += x265 + endif + + TEST.GCC.l += $(foreach m,$(MODULES.NAMES),$($m.OSL.libs))