new package: swtpm
This commit is contained in:
parent
eee4264d2a
commit
fe305abdf0
|
@ -0,0 +1,20 @@
|
|||
TERMUX_PKG_HOMEPAGE=https://github.com/stefanberger/swtpm
|
||||
TERMUX_PKG_DESCRIPTION="Software TPM Emulator"
|
||||
TERMUX_PKG_LICENSE="BSD 3-Clause"
|
||||
TERMUX_PKG_LICENSE_FILE="LICENSE"
|
||||
TERMUX_PKG_MAINTAINER="@termux"
|
||||
TERMUX_PKG_VERSION=0.8.0
|
||||
TERMUX_PKG_SRCURL=https://github.com/stefanberger/swtpm/archive/refs/tags/v${TERMUX_PKG_VERSION}.tar.gz
|
||||
TERMUX_PKG_SHA256=ad433f9272fb794aafd550914d24cc0ca33d4652cfd087fa41b911fa9e54be3d
|
||||
TERMUX_PKG_DEPENDS="glib, json-glib, libseccomp, libtpms, openssl"
|
||||
TERMUX_PKG_BUILD_DEPENDS="libtasn1"
|
||||
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
|
||||
--with-openssl
|
||||
--without-gnutls
|
||||
"
|
||||
|
||||
termux_step_pre_configure() {
|
||||
autoreconf -fi
|
||||
|
||||
CPPFLAGS+=" -Dindex=strchr"
|
||||
}
|
|
@ -0,0 +1,38 @@
|
|||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -200,14 +200,6 @@
|
||||
fi
|
||||
AM_CONDITIONAL([HAVE_TCSD], test "$have_tcsd" != "no")
|
||||
|
||||
-dnl We either need netstat (more common across systems) or 'ss' for test cases
|
||||
-AC_PATH_PROG([NETSTAT], [netstat])
|
||||
-if test "x$NETSTAT" = "x"; then
|
||||
- AC_PATH_PROG([SS], [ss])
|
||||
- if test "x$SS" = "x"; then
|
||||
- AC_MSG_ERROR(['netstat' and 'ss' tools are missing for tests: net-tools OR iproute/iproute2 package])
|
||||
- fi
|
||||
-fi
|
||||
|
||||
AC_MSG_CHECKING([for whether to build with CUSE interface])
|
||||
AC_ARG_WITH([cuse],
|
||||
@@ -384,20 +376,12 @@
|
||||
pcr_bank_checks
|
||||
AC_SUBST([DEFAULT_PCR_BANKS])
|
||||
|
||||
-AC_PATH_PROG([EXPECT], expect)
|
||||
-if test "x$EXPECT" = "x"; then
|
||||
- AC_MSG_ERROR([expect is required: expect package])
|
||||
-fi
|
||||
|
||||
AC_PATH_PROG([GAWK], gawk)
|
||||
if test "x$GAWK" = "x"; then
|
||||
AC_MSG_ERROR([gawk is required: gawk package])
|
||||
fi
|
||||
|
||||
-AC_PATH_PROG([SOCAT], socat)
|
||||
-if test "x$SOCAT" = "x"; then
|
||||
- AC_MSG_ERROR([socat is required: socat package])
|
||||
-fi
|
||||
|
||||
AC_PATH_PROG([BASE64], base64)
|
||||
if test "x$BASE64" = "x"; then
|
|
@ -0,0 +1,11 @@
|
|||
--- a/src/swtpm_setup/swtpm.c
|
||||
+++ b/src/swtpm_setup/swtpm.c
|
||||
@@ -70,7 +70,7 @@
|
||||
unsigned ctr;
|
||||
int pidfile_fd;
|
||||
int ret = 1;
|
||||
- char pidfile[] = "/tmp/.swtpm_setup.pidfile.XXXXXX";
|
||||
+ char pidfile[] = "@TERMUX_PREFIX@/tmp/.swtpm_setup.pidfile.XXXXXX";
|
||||
|
||||
pidfile_fd = mkstemp(pidfile);
|
||||
if (pidfile_fd < 0) {
|
Loading…
Reference in New Issue