new package: astra-sm

This commit is contained in:
Tee KOBAYASHI 2022-02-06 12:57:40 +09:00 committed by xtkoba
parent 72c1f22351
commit 55d891fec3
2 changed files with 55 additions and 0 deletions

View File

@ -0,0 +1,33 @@
TERMUX_PKG_HOMEPAGE=https://gitlab.com/berdyansk/astra-sm
TERMUX_PKG_DESCRIPTION="Software for digital TV broadcasting"
TERMUX_PKG_LICENSE="GPL-3.0"
TERMUX_PKG_MAINTAINER="@termux"
_COMMIT=44bcd2852b7f315233267f639730e0e21b9b6c22
TERMUX_PKG_VERSION=2019.06.19
TERMUX_PKG_SRCURL=https://github.com/OpenVisionE2/astra-sm.git
TERMUX_PKG_GIT_BRANCH=staging
TERMUX_PKG_DEPENDS="libdvbcsa, liblua53"
TERMUX_PKG_BUILD_IN_SRC=true
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
--with-lua-includes=$TERMUX_PREFIX/include/lua5.3
--with-lua-libs=$TERMUX_PREFIX/lib/liblua5.3.so
--with-lua-compiler=no
--with-ffmpeg=no
--with-libcrypto=no
"
termux_step_post_get_source() {
git fetch --unshallow
git checkout $_COMMIT
local version="$(git log -1 --format=%cs | sed 's/-/./g')"
if [ "$version" != "$TERMUX_PKG_VERSION" ]; then
echo -n "ERROR: The specified version \"$TERMUX_PKG_VERSION\""
echo " is different from what is expected to be: \"$version\""
return 1
fi
}
termux_step_pre_configure() {
autoreconf -fi
}

View File

@ -0,0 +1,22 @@
--- a/src/astra/core/spawn.c
+++ b/src/astra/core/spawn.c
@@ -148,9 +148,7 @@
static
void perror_s(const char *s)
{
- const char *msg = "Unknown error";
- if (errno < sys_nerr && sys_errlist[errno] != NULL)
- msg = sys_errlist[errno];
+ const char *msg = strerror(errno);
size_t slen;
ssize_t ret;
@@ -212,7 +210,7 @@
setsid();
/* try to run command */
- execle("/bin/sh", "sh", "-c", command, NULL, environ);
+ execle("@TERMUX_PREFIX@/bin/sh", "sh", "-c", command, NULL, environ);
perror_s("execle(): /bin/sh");
_exit(127);
}