From e10794d0644c1c08dd08477bd1da92b661b967d8 Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Tue, 25 Feb 2014 20:33:38 -0500 Subject: add a non-working libre/handbrake-svn --- libre/handbrake-svn/PKGBUILD | 171 ++++++++++++++++++++++++++++++ libre/handbrake-svn/handbrake-svn.install | 14 +++ 2 files changed, 185 insertions(+) create mode 100644 libre/handbrake-svn/PKGBUILD create mode 100644 libre/handbrake-svn/handbrake-svn.install (limited to 'libre') diff --git a/libre/handbrake-svn/PKGBUILD b/libre/handbrake-svn/PKGBUILD new file mode 100644 index 000000000..5166674d2 --- /dev/null +++ b/libre/handbrake-svn/PKGBUILD @@ -0,0 +1,171 @@ +# Maintainer: Luke Shumaker +# Maintainer (Arch): Evangelos Foutras +# Contributor (Arch): Giovanni Scafora +# Contributor (Arch): Sebastien Piccand + +pkgname=('handbrake-svn' 'handbrake-cli-svn') +_pkgver=0.9.9.1 +pkgver=6019 +url="http://handbrake.fr/" +license=('GPL') + +pkgrel=5 +arch=('i686' 'x86_64') +makedepends=('intltool' 'python2' 'gcc-libs' 'libnotify' + 'gst-plugins-base' 'gtk3' 'dbus-glib') + +# The format is: handbrake_name:[system_name|tarball] +# This list should pretty closely correspond to `grep contrib/ make/include/main.defs` +# _config_loc +# format: "ignored:pacman_pkgname" +# For packages that optionally use the system's versions. The +# build system is not modified, in order that if the module version +# is used, it fails early (assuming the network is down). +# _config_mod +# format: "module_name:file_name" +# For packages that are built as modules. +# _config_sys +# format: "module_name:pacman_pkgname" +# For modules that we *force* to be the system versions. +# _config_ign +# format: "ignored" +# For modules that are optional, but we don't want to download. +declare -ag _contrib_{loc,sys,mod,ign} +_contrib_loc+=('pkgconfig') # FEATURE.local_pkgconfig +_contrib_loc+=('autoconf' # FEATURE.local_autotools + 'automake' + 'libtool' + 'm4') +# a52dec is patched to make private things public +_contrib_mod+=('a52dec:a52dec-0.7.4.tar.gz') # always +_contrib_loc+=('bzip2') # HAS.bz2 +_contrib_loc+=('fontconfig' + 'freetype:freetype2' + 'fribidi' + 'libxml2' + 'libass' + 'libogg' + 'libvorbis' + 'libtheora' + 'libsamplerate') +#_contrib_sys+=('fdk-aac:libfdk-aac') # FEATURE.fdk_aac +_contrib_mod+=('fdk-aac:fdk-aac-v0.1.1-6-gbae4553.tar.bz2') # FEATURE.fdk_aac +_contrib_ign+=('faac') # FEATURE.faac +#_contrib_sys+=('mp4v2:libmp4v2') # FEATURE.mp4v2 +_contrib_mod+=('mp4v2:mp4v2-trunk-r355.tar.bz2') # FEATURE.mp4v2 +# libmkv is patched to add features +_contrib_mod+=('libmkv:libmkv-0.6.5-0-g82075ae.tar.gz') # FEATURE.libmkv +_contrib_sys+=('lame') # always +# Using system ffmpeg will break PGS subtitle processing +# https://forum.handbrake.fr/viewtopic.php?f=13&t=27581 +_contrib_mod+=('ffmpeg:libav-v10_alpha2.tar.bz2') # always +_contrib_sys+=('libdvdread') # always +# I don't even know, but system libdvdnav doesn't work +_contrib_mod+=('libdvdnav:libdvdnav-a5c1325.tar.bz2') # always +_contrib_sys+=('libbluray') # # always +_contrib_ign+=('libmfx') # FEATURE.qsv +_contrib_sys+=('x264') # always +_contrib_loc+=('zlib') # HAS.libz +_contrib_loc+=('yasm') # FEATURE.local_yasm + +makedepends+=("${_contrib_loc[@]#*:}" "${_contrib_sys[@]#*:}") + +source=("https://repo.parabolagnulinux.org/other/$pkgname/HandBrake-svn${pkgver}.tar.gz") +for _f in "${_contrib_mod[@]#*:}"; do + source+=("http://download.handbrake.fr/handbrake/contrib/${_f}") + noextract+=("${_f}") +done; unset _f +sha256sums=('098c2e5cad18784d3b9ac164891c87770eba055e6508bbc70d73680862473208' + '54981ab08fc09a675b9924372cf0cca5aa5363b918c4c19065c2d40e2858be47' + 'f08584d59a02db5facf548ae860c64d2870db63477f605af763c161a1508dcbc' + '5b7d4e62df506b1246463da82cc2f02415eb462e6ccd5848f98f5cdcfc1f3d4f' + '7314a296c68f42b826164074a96e247e52d8ef9287c21ebc5fe1bf9e73643e97' + '83e7f34585160a90f3c218a485e02a22a54b2fd4f1b025589bd210820dcf637e' + 'd190ce2ca4d1d9878145acd9c1b8ac76636c3b6d12066e8cc87ee674f943fb2a') + +mksource=("HandBrake-svn${pkgver}::svn://svn.handbrake.fr/HandBrake/trunk") +mkmd5sums=('SKIP') + +prepare() { + cd "$srcdir/HandBrake-svn$pkgver" + + # Use Python 2 + sed -i 's/python /python2 /' gtk/src/Makefile.am + + local contrib + # Use more system libs + for contrib in "${_contrib_sys[@]}"; do + sed -i \ + -e "s/MODULES += contrib\/${contrib%:*}\$/#& # provided by ${contrib#*:}/" \ + make/include/main.defs + done + # Use the pre-downloaded files + mkdir -p download + for contrib in "${_contrib_mod[@]}"; do + ln -srf "${srcdir}/${contrib[@]#*:}" download/ + done + + # Fix libhb to work with the stable release of libmp4v2 + if in_array libmp4v2 "${makedepends[@]}"; then + local arg='\([^,)]*\)' + sed -i \ + -e "s/MP4Close(${arg})/MP4Close(\1, 0)/" \ + -e "s/MP4Create(${arg},${arg},${arg})/MP4Create(\1,\3)/" \ + -e "s/MP4Optimize(${arg},${arg},${arg})/MP4Optimize(\1,\2)/" \ + -e "s/MP4Read(${arg},${arg})/MP4Read(\1)/" \ + libhb/decmetadata.c libhb/muxmp4.c + fi + + # Fix configure.ac to work with automake 1.13 + if in_array automake "${makedepends[@]}"; then + cd gtk + sed -i \ + -e 's/AM_CONFIG_HEADER/AC_CONFIG_HEADERS/' \ + -e '/AM_PROG_CC_STDC/d' \ + -e 's/$pkg_gudev"/gmodule-2.0 $pkg_gudev"/' \ + configure.ac + autoreconf -vi + fi +} + +build() { + cd "$srcdir/HandBrake-svn$pkgver" + + ./configure \ + --prefix=/usr \ + --force \ + --disable-gtk-update-checks + cd build + make -j1 +} + +package_handbrake-svn() { + pkgdesc="Multithreaded video transcoder" + depends=('bzip2' 'gcc-libs' 'gst-plugins-base' 'libnotify' 'dbus-glib' + 'fribidi' 'libass' 'gtk3' 'fontconfig' 'freetype2' 'libxml2' + 'libogg' 'libvorbis' 'libtheora' 'libsamplerate' 'libbluray' + 'x264' 'desktop-file-utils' 'hicolor-icon-theme') + optdepends=('gst-plugins-good: for video previews' + 'gst-libav: for video previews') + install=$pkgname.install + provides=("${pkgname%-svn}-${_pkgver}") + conflicts=("${pkgname%-svn}") + + cd "$srcdir/HandBrake-svn$pkgver/build" + + make -j1 DESTDIR="$pkgdir" install + rm "$pkgdir/usr/bin/HandBrakeCLI" +} + +package_handbrake-cli-svn() { + pkgdesc="Multithreaded video transcoder (CLI)" + depends=('bzip2' 'gcc-libs' 'zlib' 'fribidi' 'libass' 'libxml2' 'libtheora' + 'libsamplerate' 'libbluray' 'x264') + provides=("${pkgname%-svn}-${_pkgver}") + conflicts=("${pkgname%-svn}") + + cd "$srcdir/HandBrake-svn$pkgver/build" + install -D HandBrakeCLI "$pkgdir/usr/bin/HandBrakeCLI" +} + +# vim:set ts=2 sw=2 et: diff --git a/libre/handbrake-svn/handbrake-svn.install b/libre/handbrake-svn/handbrake-svn.install new file mode 100644 index 000000000..87c29e4db --- /dev/null +++ b/libre/handbrake-svn/handbrake-svn.install @@ -0,0 +1,14 @@ +post_install() { + update-desktop-database -q + gtk-update-icon-cache -q -t -f usr/share/icons/hicolor +} + +post_upgrade() { + post_install +} + +post_remove() { + post_install +} + +# vim:set ts=2 sw=2 et: -- cgit v1.2.3