# Template file for 'scrcpy'
pkgname=scrcpy
version=4.1
revision=1
build_style=meson
configure_args="-Dcompile_server=false
 -Dprebuilt_server=/usr/share/scrcpy/scrcpy-server-v${version}"
hostmakedepends="pkg-config"
makedepends="SDL3-devel ffmpeg6-devel"
depends="android-tools"
short_desc="Display and control your Android device"
maintainer="Orphaned <orphan@voidlinux.org>"
license="Apache-2.0"
homepage="https://github.com/Genymobile/scrcpy"
distfiles="https://github.com/Genymobile/scrcpy/archive/v${version}.tar.gz
 https://github.com/Genymobile/scrcpy/releases/download/v${version}/scrcpy-server-v${version}"
checksum="537b2ade623cb94b6edddfa5c61bf0b0af21484aa8365ea2531b686ea573249a
 deacb991ed2509715160ffdc7907e47b4160eb30d1566217e9047fd5b8850cae"
skip_extraction="scrcpy-server-v${version}"

post_install() {
	vinstall ${XBPS_SRCDISTDIR}/scrcpy-${version}/scrcpy-server-v${version} \
		644 /usr/share/scrcpy/ scrcpy-server
}
