desktop/mpv/PKGBUILD
2018-10-03 02:01:30 +02:00

63 lines
1.9 KiB
Bash

pkgname=mpv
pkgver=0.29.1
pkgrel=1
_waf_version=2.0.9
pkgdesc='a free, open source, and cross-platform media player'
arch=('x86_64')
# We link against libraries that are licensed GPLv3 explicitly, libsmbclient
# being one of these. So our package is GPLv3 only as well.
license=('GPL3')
url='https://mpv.io/'
depends=('desktop-file-utils' 'ffmpeg' 'hicolor-icon-theme' 'jack' 'lcms2'
'libarchive' 'libcaca' 'libcdio-paranoia' 'libdvdnav' 'libgl' 'libva'
'libxinerama' 'libxkbcommon' 'libxrandr' 'libxss' 'libxv' 'lua52'
'rubberband' 'smbclient' 'uchardet' 'vulkan-icd-loader' 'wayland'
'xdg-utils')
makedepends=('mesa' 'python3-docutils' 'ladspa' 'wayland-protocols'
'vulkan-headers')
optdepends=('youtube-dl: for video-sharing websites playback')
options=('!emptydirs')
source=("$pkgname-$pkgver.tar.gz::https://github.com/mpv-player/$pkgname/archive/v$pkgver.tar.gz"
"https://waf.io/waf-${_waf_version}")
sha256sums=('f9f9d461d1990f9728660b4ccb0e8cb5dce29ccaa6af567bec481b79291ca623'
'2a8e0816f023995e557f79ea8940d322bec18f286917c8f9a6fa2dc3875dfa48')
prepare() {
cd ${pkgname}-${pkgver}
install -m755 "${srcdir}"/waf-${_waf_version} waf
}
build() {
cd ${pkgname}-${pkgver}
./waf configure --prefix=/usr \
--confdir=/etc/mpv \
--enable-cdda \
--enable-dvb \
--enable-dvdnav \
--enable-libarchive \
--enable-libmpv-shared \
--enable-libsmbclient \
--enable-tv \
--enable-zsh-comp
./waf build
}
package() {
cd ${pkgname}-${pkgver}
./waf install --destdir="$pkgdir"
install -d "${pkgdir}/usr/share/doc/mpv/examples"
# some extra useful stuff "make install" doesn't install
install -m755 TOOLS/umpv \
"${pkgdir}"/usr/bin/umpv
install -m644 etc/input.conf \
"${pkgdir}"/usr/share/doc/mpv/examples
install -m644 DOCS/{encoding.rst,tech-overview.txt} \
"$pkgdir"/usr/share/doc/mpv
}