void-packages/srcpkgs/mpv/template
2021-12-31 18:16:34 +01:00

62 lines
2.6 KiB
Bash

# Template file for 'mpv'
pkgname=mpv
version=0.34.0
revision=1
build_style=waf3
configure_args="--confdir=/etc/mpv --docdir=/usr/share/examples/mpv
--enable-cdda --enable-dvbin --enable-dvdnav --enable-libarchive
--enable-libmpv-shared --enable-cplugins $(vopt_enable alsa) $(vopt_enable caca)
$(vopt_enable jack) $(vopt_enable lcms lcms2) $(vopt_enable lua)
$(vopt_enable openal) $(vopt_enable pulseaudio pulse) $(vopt_enable sdl2)
$(vopt_enable vapoursynth) $(vopt_enable vdpau) $(vopt_enable vulkan)
$(vopt_enable vulkan shaderc) $(vopt_enable wayland) $(vopt_enable x11)"
hostmakedepends="pkg-config python3-docutils $(vopt_if wayland wayland-devel)"
makedepends="MesaLib-devel ffmpeg-devel harfbuzz-devel libXv-devel
libass-devel libbluray-devel libcdio-paranoia-devel libdvdnav-devel
llibuuid-devel libva-devel rubberband-devel uchardet-devel
libarchive-devel $(vopt_if alsa alsa-lib-devel) $(vopt_if caca libcaca-devel)
$(vopt_if jack jack-devel) $(vopt_if lcms lcms2-devel)
$(vopt_if lua lua52-devel) $(vopt_if openal libopenal-devel)
$(vopt_if pulseaudio pulseaudio-devel) $(vopt_if sdl2 SDL2-devel)
$(vopt_if vapoursynth vapoursynth-devel) $(vopt_if vdpau libvdpau-devel)
$(vopt_if vulkan "Vulkan-Headers vulkan-loader shaderc libplacebo-devel")
$(vopt_if wayland "wayland-devel wayland-protocols libxkbcommon-devel")
$(vopt_if x11 "libXScrnSaver-devel libXinerama-devel libXrandr-devel")"
depends="desktop-file-utils hicolor-icon-theme $(vopt_if vapoursynth vapoursynth-mvtools)"
short_desc="Video player based on MPlayer/mplayer2"
maintainer="travankor <travankor@tuta.io>"
license="GPL-2.0-or-later"
homepage="https://mpv.io"
changelog="https://github.com/mpv-player/mpv/releases"
distfiles="https://github.com/mpv-player/${pkgname}/archive/v${version}.tar.gz"
checksum=f654fb6275e5178f57e055d20918d7d34e19949bc98ebbf4a7371902e88ce309
if [ "$XBPS_TARGET_NO_ATOMIC8" ]; then
makedepends+=" libatomic-devel"
fi
build_options="alsa caca jack lcms lua openal pulseaudio sdl2 vapoursynth vdpau
vulkan wayland x11"
build_options_default="alsa jack lcms lua pulseaudio vdpau vulkan wayland x11"
desc_option_caca="Enable support for libcaca video output"
desc_option_lcms="Enable support for LittleCMS 2 engine"
desc_option_openal="Enable support for OpenAL audio output"
vopt_conflict sdl2 wayland
if [ -z "$CROSS_BUILD" ]; then
configure_args+=" --zshdir=/usr/share/zsh/site-functions"
fi
pre_configure() {
python3 bootstrap.py
}
mpv-devel_package() {
depends="${sourcepkg}>=${version}_${revision}"
short_desc+=" - development files"
pkg_install() {
vmove usr/include
vmove usr/lib/pkgconfig
vmove usr/lib/*.so
}
}