0
0
mirror of https://github.com/termux/termux-packages.git synced 2024-11-23 13:46:16 +00:00
termux-packages/x11-packages/scrcpy/build.sh
Termux Github Actions c54236320a bump(x11/scrcpy): 2.7
This commit has been automatically submitted by Github Actions.
2024-09-16 00:36:39 +00:00

22 lines
1.2 KiB
Bash

TERMUX_PKG_HOMEPAGE=https://github.com/Genymobile/scrcpy
TERMUX_PKG_DESCRIPTION="Provides display and control of Android devices connected via USB or over TCP/IP"
TERMUX_PKG_LICENSE="Apache-2.0"
TERMUX_PKG_MAINTAINER="@termux"
TERMUX_PKG_VERSION="2.7"
TERMUX_PKG_SRCURL=https://github.com/Genymobile/scrcpy/archive/refs/tags/v${TERMUX_PKG_VERSION}.tar.gz
TERMUX_PKG_SHA256=3ceea215f6eccb59535f68a16db6db2b05a8a1c91bdcb4a6e222d3093a9daf8c
TERMUX_PKG_AUTO_UPDATE=true
TERMUX_PKG_DEPENDS="android-tools, ffmpeg, libusb, sdl2"
TERMUX_PKG_ANTI_BUILD_DEPENDS="android-tools"
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
-Dprebuilt_server=$TERMUX_PKG_SRCDIR/scrcpy-server-v${TERMUX_PKG_VERSION}
"
termux_step_post_get_source() {
local _url=https://github.com/Genymobile/scrcpy/releases/download/v${TERMUX_PKG_VERSION}/scrcpy-server-v${TERMUX_PKG_VERSION}
termux_download ${_url} $(basename ${_url}) SKIP_CHECKSUM
# We are skipping checksum checking, but we should ensure it is android package.
[[ "$(file $(basename ${_url}))"==*"Android package"* || "$(file $(basename ${_url}))"==*"Zip archive data"* ]] \
|| termux_error_exit "$(basename ${_url}) has wrong signature: $(file $(basename ${_url}))"
}