desktop/mpv/PKGBUILD

70 lines
2.1 KiB
Bash
Raw Normal View History

2014-02-03 17:59:56 +08:00
pkgname=mpv
2017-09-13 20:28:29 +08:00
pkgver=0.27.0
2017-03-22 07:47:07 +08:00
pkgrel=1
2014-02-03 17:59:56 +08:00
pkgdesc="A movie player and encoder for linux, based on MPlayer/mplayer2"
arch=('x86_64')
license=('LGPL3')
2014-02-03 17:59:56 +08:00
url="http://mpv.io"
depends=('pulseaudio' 'ffmpeg' 'lcms2' 'libdvdread' 'libgl' 'libvdpau'
2015-10-29 22:11:01 +08:00
'libxinerama' 'libxv' 'libxkbcommon' 'libva' 'libass' 'uchardet'
'wayland' 'desktop-file-utils' 'hicolor-icon-theme' 'v4l-utils' 'openal'
2016-09-25 01:06:42 +08:00
'xdg-utils' 'lua52' 'libdvdnav' 'libcdio-paranoia' 'libbluray' 'libxss'
2017-07-21 12:50:07 +08:00
'enca' 'libguess' 'harfbuzz' 'libxrandr' 'rubberband' 'libarchive' 'libcaca')
makedepends=('mesa' 'python3-docutils' 'ladspa' 'x264' 'jack' 'samba' 'waf')
2015-01-28 23:14:17 +08:00
options=('!emptydirs')
provides=('mplayer')
2014-02-03 17:59:56 +08:00
install=${pkgname}.install
2017-07-21 12:50:07 +08:00
source=("https://github.com/mpv-player/${pkgname}/archive/v${pkgver}.tar.gz"
'0001-opengl-backend-support-multiple-backends.patch')
2017-09-13 20:28:29 +08:00
sha256sums=('341d8bf18b75c1f78d5b681480b5b7f5c8b87d97a0d4f53a5648ede9c219a49c'
2017-07-21 12:50:07 +08:00
'609e0530f1b0cdb910dcffb5f62bf55936540e24105ce1b2daf1bd6291a7d58a')
prepare() {
cd ${pkgname}-${pkgver}
# --opengl-backend: support multiple backends (#4384) (FS#53962)
patch -Np1 < "${srcdir}"/0001-opengl-backend-support-multiple-backends.patch
}
2014-02-03 17:59:56 +08:00
build() {
2014-07-16 03:40:57 +08:00
cd ${pkgname}-${pkgver}
2014-02-03 17:59:56 +08:00
2015-02-27 14:05:25 +08:00
# disable SDL, since they are just legacy drivers
2016-04-06 06:12:55 +08:00
waf configure \
2014-07-16 03:40:57 +08:00
--prefix=/usr \
--confdir=/etc/mpv \
--enable-libmpv-shared \
--enable-cdda \
2017-07-21 12:50:07 +08:00
--enable-dvb \
2014-07-16 03:40:57 +08:00
--enable-zsh-comp \
2015-10-29 22:11:01 +08:00
--enable-alsa \
2014-07-16 03:40:57 +08:00
--enable-pulse \
2015-01-28 23:14:17 +08:00
--enable-openal \
2015-01-28 17:14:38 +08:00
--enable-wayland \
--enable-gl-wayland \
2015-01-28 23:14:17 +08:00
--enable-egl-x11 \
--enable-libsmbclient \
2015-10-29 22:11:01 +08:00
--enable-dvdread \
2016-10-20 15:36:02 +08:00
--enable-vdpau \
2017-07-21 12:50:07 +08:00
--enable-encoding \
--enable-dvdnav \
--enable-libarchive
2016-04-06 06:12:55 +08:00
waf build
2014-02-03 17:59:56 +08:00
}
package() {
2014-07-16 03:40:57 +08:00
cd ${pkgname}-${pkgver}
2014-02-03 17:59:56 +08:00
2016-04-06 06:12:55 +08:00
waf install --destdir="${pkgdir}"
2014-02-03 17:59:56 +08:00
2014-07-16 03:40:57 +08:00
install -d "${pkgdir}/usr/share/doc/mpv/examples"
2014-02-03 17:59:56 +08:00
# some extra useful stuff "make install" doesn't install
2014-10-05 10:00:34 +08:00
install -m755 TOOLS/umpv \
"${pkgdir}"/usr/bin/umpv
2016-01-19 08:27:56 +08:00
install -m644 etc/input.conf \
2014-07-16 03:40:57 +08:00
"${pkgdir}"/usr/share/doc/mpv/examples
2014-04-24 05:29:56 +08:00
install -m644 DOCS/{encoding.rst,tech-overview.txt} \
2014-07-16 03:40:57 +08:00
"${pkgdir}"/usr/share/doc/mpv
2014-02-03 17:59:56 +08:00
}