Blame SOURCES/0133-tests-check-decoding-of-tgkill-syscall.patch

c5cada
From 9d4d64f6fdfcae908aec455888e92a69c9c81c64 Mon Sep 17 00:00:00 2001
c5cada
From: "Dmitry V. Levin" <ldv@altlinux.org>
c5cada
Date: Sat, 1 Aug 2020 08:00:00 +0000
c5cada
Subject: [PATCH 133/138] tests: check decoding of tgkill syscall
c5cada
c5cada
* tests/tgkill.c: New file.
c5cada
* tests/gen_tests.in (tgkill): New entry.
c5cada
* tests/pure_executables.list: Add tgkill.
c5cada
* tests/.gitignore: Likewise.
c5cada
---
c5cada
 tests/.gitignore            |  1 +
c5cada
 tests/gen_tests.in          |  1 +
c5cada
 tests/pure_executables.list |  1 +
c5cada
 tests/tgkill.c              | 69 +++++++++++++++++++++++++++++++++++++++++++++
c5cada
 4 files changed, 72 insertions(+)
c5cada
 create mode 100644 tests/tgkill.c
c5cada
c5cada
Index: strace-5.7/tests/gen_tests.in
c5cada
===================================================================
c5cada
--- strace-5.7.orig/tests/gen_tests.in	2020-09-09 19:30:36.780885588 +0200
c5cada
+++ strace-5.7/tests/gen_tests.in	2020-09-09 19:32:50.740965435 +0200
c5cada
@@ -658,6 +658,7 @@
c5cada
 sysinfo	-a14
c5cada
 syslog	-a35
c5cada
 tee
c5cada
+tgkill	-a15 --signal='!cont'
c5cada
 threads-execve--quiet-thread-execve +threads-execve.test -s40 --quiet=personality,thread-execve
c5cada
 threads-execve-q +threads-execve.test -q
c5cada
 threads-execve-qq +threads-execve.test -qq
c5cada
Index: strace-5.7/tests/pure_executables.list
c5cada
===================================================================
c5cada
--- strace-5.7.orig/tests/pure_executables.list	2020-09-09 19:30:36.780885588 +0200
c5cada
+++ strace-5.7/tests/pure_executables.list	2020-09-09 19:32:45.308962197 +0200
c5cada
@@ -583,6 +583,7 @@
c5cada
 sysinfo
c5cada
 syslog
c5cada
 tee
c5cada
+tgkill
c5cada
 time
c5cada
 timer_create
c5cada
 timer_xettime
c5cada
Index: strace-5.7/tests/tgkill.c
c5cada
===================================================================
c5cada
--- /dev/null	1970-01-01 00:00:00.000000000 +0000
c5cada
+++ strace-5.7/tests/tgkill.c	2020-09-09 19:32:50.740965435 +0200
c5cada
@@ -0,0 +1,69 @@
c5cada
+/*
c5cada
+ * Check decoding of tgkill syscall.
c5cada
+ *
c5cada
+ * Copyright (c) 2020 Dmitry V. Levin <ldv@altlinux.org>
c5cada
+ * All rights reserved.
c5cada
+ *
c5cada
+ * SPDX-License-Identifier: GPL-2.0-or-later
c5cada
+ */
c5cada
+
c5cada
+#include "tests.h"
c5cada
+#include "scno.h"
c5cada
+
c5cada
+#ifdef __NR_tgkill
c5cada
+
c5cada
+# include <signal.h>
c5cada
+# include <stdio.h>
c5cada
+# include <unistd.h>
c5cada
+
c5cada
+static const char *errstr;
c5cada
+
c5cada
+static long
c5cada
+k_tgkill(const unsigned int tgid,
c5cada
+	 const unsigned int tid,
c5cada
+	 const unsigned int sig)
c5cada
+{
c5cada
+        const kernel_ulong_t fill = (kernel_ulong_t) 0xdefaced00000000ULL;
c5cada
+        const kernel_ulong_t bad = (kernel_ulong_t) 0xbadc0dedbadc0dedULL;
c5cada
+        const kernel_ulong_t arg1 = fill | tgid;
c5cada
+        const kernel_ulong_t arg2 = fill | tid;
c5cada
+        const kernel_ulong_t arg3 = fill | sig;
c5cada
+        const long rc = syscall(__NR_tgkill, arg1, arg2, arg3, bad, bad, bad);
c5cada
+        errstr = sprintrc(rc);
c5cada
+        return rc;
c5cada
+}
c5cada
+
c5cada
+int
c5cada
+main(void)
c5cada
+{
c5cada
+	const int pid = getpid();
c5cada
+	const int bad_pid = -1;
c5cada
+	const int bad_sig = 0xface;
c5cada
+
c5cada
+	k_tgkill(pid, pid, 0);
c5cada
+	printf("tgkill(%d, %d, 0) = %s\n", pid, pid, errstr);
c5cada
+
c5cada
+	k_tgkill(pid, bad_pid, 0);
c5cada
+	printf("tgkill(%d, %d, 0) = %s\n", pid, bad_pid, errstr);
c5cada
+
c5cada
+	k_tgkill(bad_pid, pid, 0);
c5cada
+	printf("tgkill(%d, %d, 0) = %s\n", bad_pid, pid, errstr);
c5cada
+
c5cada
+	k_tgkill(pid, pid, SIGCONT);
c5cada
+	printf("tgkill(%d, %d, SIGCONT) = %s\n", pid, pid, errstr);
c5cada
+
c5cada
+	k_tgkill(pid, pid, bad_sig);
c5cada
+	printf("tgkill(%d, %d, %d) = %s\n", pid, pid, bad_sig, errstr);
c5cada
+
c5cada
+	k_tgkill(pid, pid, -bad_sig);
c5cada
+	printf("tgkill(%d, %d, %d) = %s\n", pid, pid, -bad_sig, errstr);
c5cada
+
c5cada
+	puts("+++ exited with 0 +++");
c5cada
+	return 0;
c5cada
+}
c5cada
+
c5cada
+#else
c5cada
+
c5cada
+SKIP_MAIN_UNDEFINED("__NR_tgkill")
c5cada
+
c5cada
+#endif
c5cada
Index: strace-5.7/tests-m32/gen_tests.in
c5cada
===================================================================
c5cada
--- strace-5.7.orig/tests-m32/gen_tests.in	2020-09-09 19:30:36.780885588 +0200
c5cada
+++ strace-5.7/tests-m32/gen_tests.in	2020-09-09 19:32:50.740965435 +0200
c5cada
@@ -658,6 +658,7 @@
c5cada
 sysinfo	-a14
c5cada
 syslog	-a35
c5cada
 tee
c5cada
+tgkill	-a15 --signal='!cont'
c5cada
 threads-execve--quiet-thread-execve +threads-execve.test -s40 --quiet=personality,thread-execve
c5cada
 threads-execve-q +threads-execve.test -q
c5cada
 threads-execve-qq +threads-execve.test -qq
c5cada
Index: strace-5.7/tests-m32/pure_executables.list
c5cada
===================================================================
c5cada
--- strace-5.7.orig/tests-m32/pure_executables.list	2020-09-09 19:30:36.780885588 +0200
c5cada
+++ strace-5.7/tests-m32/pure_executables.list	2020-09-09 19:32:45.309962197 +0200
c5cada
@@ -583,6 +583,7 @@
c5cada
 sysinfo
c5cada
 syslog
c5cada
 tee
c5cada
+tgkill
c5cada
 time
c5cada
 timer_create
c5cada
 timer_xettime
c5cada
Index: strace-5.7/tests-m32/tgkill.c
c5cada
===================================================================
c5cada
--- /dev/null	1970-01-01 00:00:00.000000000 +0000
c5cada
+++ strace-5.7/tests-m32/tgkill.c	2020-09-09 19:32:50.740965435 +0200
c5cada
@@ -0,0 +1,69 @@
c5cada
+/*
c5cada
+ * Check decoding of tgkill syscall.
c5cada
+ *
c5cada
+ * Copyright (c) 2020 Dmitry V. Levin <ldv@altlinux.org>
c5cada
+ * All rights reserved.
c5cada
+ *
c5cada
+ * SPDX-License-Identifier: GPL-2.0-or-later
c5cada
+ */
c5cada
+
c5cada
+#include "tests.h"
c5cada
+#include "scno.h"
c5cada
+
c5cada
+#ifdef __NR_tgkill
c5cada
+
c5cada
+# include <signal.h>
c5cada
+# include <stdio.h>
c5cada
+# include <unistd.h>
c5cada
+
c5cada
+static const char *errstr;
c5cada
+
c5cada
+static long
c5cada
+k_tgkill(const unsigned int tgid,
c5cada
+	 const unsigned int tid,
c5cada
+	 const unsigned int sig)
c5cada
+{
c5cada
+        const kernel_ulong_t fill = (kernel_ulong_t) 0xdefaced00000000ULL;
c5cada
+        const kernel_ulong_t bad = (kernel_ulong_t) 0xbadc0dedbadc0dedULL;
c5cada
+        const kernel_ulong_t arg1 = fill | tgid;
c5cada
+        const kernel_ulong_t arg2 = fill | tid;
c5cada
+        const kernel_ulong_t arg3 = fill | sig;
c5cada
+        const long rc = syscall(__NR_tgkill, arg1, arg2, arg3, bad, bad, bad);
c5cada
+        errstr = sprintrc(rc);
c5cada
+        return rc;
c5cada
+}
c5cada
+
c5cada
+int
c5cada
+main(void)
c5cada
+{
c5cada
+	const int pid = getpid();
c5cada
+	const int bad_pid = -1;
c5cada
+	const int bad_sig = 0xface;
c5cada
+
c5cada
+	k_tgkill(pid, pid, 0);
c5cada
+	printf("tgkill(%d, %d, 0) = %s\n", pid, pid, errstr);
c5cada
+
c5cada
+	k_tgkill(pid, bad_pid, 0);
c5cada
+	printf("tgkill(%d, %d, 0) = %s\n", pid, bad_pid, errstr);
c5cada
+
c5cada
+	k_tgkill(bad_pid, pid, 0);
c5cada
+	printf("tgkill(%d, %d, 0) = %s\n", bad_pid, pid, errstr);
c5cada
+
c5cada
+	k_tgkill(pid, pid, SIGCONT);
c5cada
+	printf("tgkill(%d, %d, SIGCONT) = %s\n", pid, pid, errstr);
c5cada
+
c5cada
+	k_tgkill(pid, pid, bad_sig);
c5cada
+	printf("tgkill(%d, %d, %d) = %s\n", pid, pid, bad_sig, errstr);
c5cada
+
c5cada
+	k_tgkill(pid, pid, -bad_sig);
c5cada
+	printf("tgkill(%d, %d, %d) = %s\n", pid, pid, -bad_sig, errstr);
c5cada
+
c5cada
+	puts("+++ exited with 0 +++");
c5cada
+	return 0;
c5cada
+}
c5cada
+
c5cada
+#else
c5cada
+
c5cada
+SKIP_MAIN_UNDEFINED("__NR_tgkill")
c5cada
+
c5cada
+#endif
c5cada
Index: strace-5.7/tests-mx32/gen_tests.in
c5cada
===================================================================
c5cada
--- strace-5.7.orig/tests-mx32/gen_tests.in	2020-09-09 19:30:36.780885588 +0200
c5cada
+++ strace-5.7/tests-mx32/gen_tests.in	2020-09-09 19:32:50.740965435 +0200
c5cada
@@ -658,6 +658,7 @@
c5cada
 sysinfo	-a14
c5cada
 syslog	-a35
c5cada
 tee
c5cada
+tgkill	-a15 --signal='!cont'
c5cada
 threads-execve--quiet-thread-execve +threads-execve.test -s40 --quiet=personality,thread-execve
c5cada
 threads-execve-q +threads-execve.test -q
c5cada
 threads-execve-qq +threads-execve.test -qq
c5cada
Index: strace-5.7/tests-mx32/pure_executables.list
c5cada
===================================================================
c5cada
--- strace-5.7.orig/tests-mx32/pure_executables.list	2020-09-09 19:30:36.780885588 +0200
c5cada
+++ strace-5.7/tests-mx32/pure_executables.list	2020-09-09 19:32:45.310962198 +0200
c5cada
@@ -583,6 +583,7 @@
c5cada
 sysinfo
c5cada
 syslog
c5cada
 tee
c5cada
+tgkill
c5cada
 time
c5cada
 timer_create
c5cada
 timer_xettime
c5cada
Index: strace-5.7/tests-mx32/tgkill.c
c5cada
===================================================================
c5cada
--- /dev/null	1970-01-01 00:00:00.000000000 +0000
c5cada
+++ strace-5.7/tests-mx32/tgkill.c	2020-09-09 19:32:50.740965435 +0200
c5cada
@@ -0,0 +1,69 @@
c5cada
+/*
c5cada
+ * Check decoding of tgkill syscall.
c5cada
+ *
c5cada
+ * Copyright (c) 2020 Dmitry V. Levin <ldv@altlinux.org>
c5cada
+ * All rights reserved.
c5cada
+ *
c5cada
+ * SPDX-License-Identifier: GPL-2.0-or-later
c5cada
+ */
c5cada
+
c5cada
+#include "tests.h"
c5cada
+#include "scno.h"
c5cada
+
c5cada
+#ifdef __NR_tgkill
c5cada
+
c5cada
+# include <signal.h>
c5cada
+# include <stdio.h>
c5cada
+# include <unistd.h>
c5cada
+
c5cada
+static const char *errstr;
c5cada
+
c5cada
+static long
c5cada
+k_tgkill(const unsigned int tgid,
c5cada
+	 const unsigned int tid,
c5cada
+	 const unsigned int sig)
c5cada
+{
c5cada
+        const kernel_ulong_t fill = (kernel_ulong_t) 0xdefaced00000000ULL;
c5cada
+        const kernel_ulong_t bad = (kernel_ulong_t) 0xbadc0dedbadc0dedULL;
c5cada
+        const kernel_ulong_t arg1 = fill | tgid;
c5cada
+        const kernel_ulong_t arg2 = fill | tid;
c5cada
+        const kernel_ulong_t arg3 = fill | sig;
c5cada
+        const long rc = syscall(__NR_tgkill, arg1, arg2, arg3, bad, bad, bad);
c5cada
+        errstr = sprintrc(rc);
c5cada
+        return rc;
c5cada
+}
c5cada
+
c5cada
+int
c5cada
+main(void)
c5cada
+{
c5cada
+	const int pid = getpid();
c5cada
+	const int bad_pid = -1;
c5cada
+	const int bad_sig = 0xface;
c5cada
+
c5cada
+	k_tgkill(pid, pid, 0);
c5cada
+	printf("tgkill(%d, %d, 0) = %s\n", pid, pid, errstr);
c5cada
+
c5cada
+	k_tgkill(pid, bad_pid, 0);
c5cada
+	printf("tgkill(%d, %d, 0) = %s\n", pid, bad_pid, errstr);
c5cada
+
c5cada
+	k_tgkill(bad_pid, pid, 0);
c5cada
+	printf("tgkill(%d, %d, 0) = %s\n", bad_pid, pid, errstr);
c5cada
+
c5cada
+	k_tgkill(pid, pid, SIGCONT);
c5cada
+	printf("tgkill(%d, %d, SIGCONT) = %s\n", pid, pid, errstr);
c5cada
+
c5cada
+	k_tgkill(pid, pid, bad_sig);
c5cada
+	printf("tgkill(%d, %d, %d) = %s\n", pid, pid, bad_sig, errstr);
c5cada
+
c5cada
+	k_tgkill(pid, pid, -bad_sig);
c5cada
+	printf("tgkill(%d, %d, %d) = %s\n", pid, pid, -bad_sig, errstr);
c5cada
+
c5cada
+	puts("+++ exited with 0 +++");
c5cada
+	return 0;
c5cada
+}
c5cada
+
c5cada
+#else
c5cada
+
c5cada
+SKIP_MAIN_UNDEFINED("__NR_tgkill")
c5cada
+
c5cada
+#endif
c5cada
Index: strace-5.7/tests-m32/Makefile.in
c5cada
===================================================================
c5cada
--- strace-5.7.orig/tests-m32/Makefile.in	2020-09-09 19:32:14.800944013 +0200
c5cada
+++ strace-5.7/tests-m32/Makefile.in	2020-09-09 19:49:34.530563739 +0200
c5cada
@@ -493,8 +493,8 @@
c5cada
 	strace-xx$(EXEEXT) swap$(EXEEXT) sxetmask$(EXEEXT) \
c5cada
 	symlink$(EXEEXT) symlinkat$(EXEEXT) sync$(EXEEXT) \
c5cada
 	sync_file_range$(EXEEXT) sync_file_range2$(EXEEXT) \
c5cada
-	sysinfo$(EXEEXT) syslog$(EXEEXT) tee$(EXEEXT) time$(EXEEXT) \
c5cada
-	timer_create$(EXEEXT) timer_xettime$(EXEEXT) \
c5cada
+	sysinfo$(EXEEXT) syslog$(EXEEXT) tee$(EXEEXT) tgkill$(EXEEXT) \
c5cada
+	time$(EXEEXT) timer_create$(EXEEXT) timer_xettime$(EXEEXT) \
c5cada
 	timerfd_xettime$(EXEEXT) times$(EXEEXT) times-fail$(EXEEXT) \
c5cada
 	tkill$(EXEEXT) truncate$(EXEEXT) truncate64$(EXEEXT) \
c5cada
 	ugetrlimit$(EXEEXT) uio$(EXEEXT) umask$(EXEEXT) \
c5cada
@@ -3444,6 +3444,10 @@
c5cada
 tee_OBJECTS = tee.$(OBJEXT)
c5cada
 tee_LDADD = $(LDADD)
c5cada
 tee_DEPENDENCIES = libtests.a
c5cada
+tgkill_SOURCES = tgkill.c
c5cada
+tgkill_OBJECTS = tgkill.$(OBJEXT)
c5cada
+tgkill_LDADD = $(LDADD)
c5cada
+tgkill_DEPENDENCIES = libtests.a
c5cada
 threads_execve_SOURCES = threads-execve.c
c5cada
 threads_execve_OBJECTS = threads-execve.$(OBJEXT)
c5cada
 threads_execve_DEPENDENCIES = $(am__DEPENDENCIES_1) $(LDADD)
c5cada
@@ -4181,7 +4185,7 @@
c5cada
 	./$(DEPDIR)/symlinkat.Po ./$(DEPDIR)/sync.Po \
c5cada
 	./$(DEPDIR)/sync_file_range.Po ./$(DEPDIR)/sync_file_range2.Po \
c5cada
 	./$(DEPDIR)/sysinfo.Po ./$(DEPDIR)/syslog-success.Po \
c5cada
-	./$(DEPDIR)/syslog.Po ./$(DEPDIR)/tee.Po \
c5cada
+	./$(DEPDIR)/syslog.Po ./$(DEPDIR)/tee.Po ./$(DEPDIR)/tgkill.Po \
c5cada
 	./$(DEPDIR)/threads-execve--quiet-thread-execve.Po \
c5cada
 	./$(DEPDIR)/threads-execve-q.Po \
c5cada
 	./$(DEPDIR)/threads-execve-qq.Po \
c5cada
@@ -4443,7 +4447,7 @@
c5cada
 	strace--strings-in-hex-non-ascii.c strace-x.c strace-xx.c \
c5cada
 	swap.c sxetmask.c symlink.c symlinkat.c sync.c \
c5cada
 	sync_file_range.c sync_file_range2.c sysinfo.c syslog.c \
c5cada
-	syslog-success.c tee.c threads-execve.c \
c5cada
+	syslog-success.c tee.c tgkill.c threads-execve.c \
c5cada
 	threads-execve--quiet-thread-execve.c threads-execve-q.c \
c5cada
 	threads-execve-qq.c threads-execve-qqq.c time.c timer_create.c \
c5cada
 	timer_xettime.c timerfd_xettime.c times.c times-fail.c tkill.c \
c5cada
@@ -4669,7 +4673,7 @@
c5cada
 	strace--strings-in-hex-non-ascii.c strace-x.c strace-xx.c \
c5cada
 	swap.c sxetmask.c symlink.c symlinkat.c sync.c \
c5cada
 	sync_file_range.c sync_file_range2.c sysinfo.c syslog.c \
c5cada
-	syslog-success.c tee.c threads-execve.c \
c5cada
+	syslog-success.c tee.c tgkill.c threads-execve.c \
c5cada
 	threads-execve--quiet-thread-execve.c threads-execve-q.c \
c5cada
 	threads-execve-qq.c threads-execve-qqq.c time.c timer_create.c \
c5cada
 	timer_xettime.c timerfd_xettime.c times.c times-fail.c tkill.c \
c5cada
@@ -5724,6 +5728,7 @@
c5cada
   sysinfo \
c5cada
   syslog \
c5cada
   tee \
c5cada
+  tgkill \
c5cada
   time \
c5cada
   timer_create \
c5cada
   timer_xettime \
c5cada
@@ -6133,7 +6138,7 @@
c5cada
 	strace-xx.gen.test swap.gen.test sxetmask.gen.test \
c5cada
 	symlink.gen.test symlinkat.gen.test sync.gen.test \
c5cada
 	sync_file_range.gen.test sync_file_range2.gen.test \
c5cada
-	sysinfo.gen.test syslog.gen.test tee.gen.test \
c5cada
+	sysinfo.gen.test syslog.gen.test tee.gen.test tgkill.gen.test \
c5cada
 	threads-execve--quiet-thread-execve.gen.test \
c5cada
 	threads-execve-q.gen.test threads-execve-qq.gen.test \
c5cada
 	threads-execve-qqq.gen.test time.gen.test \
c5cada
@@ -9355,6 +9360,10 @@
c5cada
 	@rm -f tee$(EXEEXT)
c5cada
 	$(AM_V_CCLD)$(LINK) $(tee_OBJECTS) $(tee_LDADD) $(LIBS)
c5cada
 
c5cada
+tgkill$(EXEEXT): $(tgkill_OBJECTS) $(tgkill_DEPENDENCIES) $(EXTRA_tgkill_DEPENDENCIES) 
c5cada
+	@rm -f tgkill$(EXEEXT)
c5cada
+	$(AM_V_CCLD)$(LINK) $(tgkill_OBJECTS) $(tgkill_LDADD) $(LIBS)
c5cada
+
c5cada
 threads-execve$(EXEEXT): $(threads_execve_OBJECTS) $(threads_execve_DEPENDENCIES) $(EXTRA_threads_execve_DEPENDENCIES) 
c5cada
 	@rm -f threads-execve$(EXEEXT)
c5cada
 	$(AM_V_CCLD)$(LINK) $(threads_execve_OBJECTS) $(threads_execve_LDADD) $(LIBS)
c5cada
@@ -10349,6 +10358,7 @@
c5cada
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/syslog-success.Po@am__quote@ # am--include-marker
c5cada
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/syslog.Po@am__quote@ # am--include-marker
c5cada
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tee.Po@am__quote@ # am--include-marker
c5cada
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tgkill.Po@am__quote@ # am--include-marker
c5cada
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/threads-execve--quiet-thread-execve.Po@am__quote@ # am--include-marker
c5cada
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/threads-execve-q.Po@am__quote@ # am--include-marker
c5cada
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/threads-execve-qq.Po@am__quote@ # am--include-marker
c5cada
@@ -12170,6 +12180,7 @@
c5cada
 	-rm -f ./$(DEPDIR)/syslog-success.Po
c5cada
 	-rm -f ./$(DEPDIR)/syslog.Po
c5cada
 	-rm -f ./$(DEPDIR)/tee.Po
c5cada
+	-rm -f ./$(DEPDIR)/tgkill.Po
c5cada
 	-rm -f ./$(DEPDIR)/threads-execve--quiet-thread-execve.Po
c5cada
 	-rm -f ./$(DEPDIR)/threads-execve-q.Po
c5cada
 	-rm -f ./$(DEPDIR)/threads-execve-qq.Po
c5cada
@@ -13026,6 +13037,7 @@
c5cada
 	-rm -f ./$(DEPDIR)/syslog-success.Po
c5cada
 	-rm -f ./$(DEPDIR)/syslog.Po
c5cada
 	-rm -f ./$(DEPDIR)/tee.Po
c5cada
+	-rm -f ./$(DEPDIR)/tgkill.Po
c5cada
 	-rm -f ./$(DEPDIR)/threads-execve--quiet-thread-execve.Po
c5cada
 	-rm -f ./$(DEPDIR)/threads-execve-q.Po
c5cada
 	-rm -f ./$(DEPDIR)/threads-execve-qq.Po
c5cada
@@ -15085,6 +15097,9 @@
c5cada
 $(srcdir)/tee.gen.test: $(abs_srcdir)/gen_tests.sh $(srcdir)/gen_tests.in
c5cada
 	$(AM_V_GEN) $^ $@
c5cada
 
c5cada
+$(srcdir)/tgkill.gen.test: $(abs_srcdir)/gen_tests.sh $(srcdir)/gen_tests.in
c5cada
+	$(AM_V_GEN) $^ $@
c5cada
+
c5cada
 $(srcdir)/threads-execve--quiet-thread-execve.gen.test: $(abs_srcdir)/gen_tests.sh $(srcdir)/gen_tests.in
c5cada
 	$(AM_V_GEN) $^ $@
c5cada
 
c5cada
Index: strace-5.7/tests-mx32/Makefile.in
c5cada
===================================================================
c5cada
--- strace-5.7.orig/tests-mx32/Makefile.in	2020-09-09 19:32:39.854958946 +0200
c5cada
+++ strace-5.7/tests-mx32/Makefile.in	2020-09-09 19:49:39.557566736 +0200
c5cada
@@ -493,8 +493,8 @@
c5cada
 	strace-xx$(EXEEXT) swap$(EXEEXT) sxetmask$(EXEEXT) \
c5cada
 	symlink$(EXEEXT) symlinkat$(EXEEXT) sync$(EXEEXT) \
c5cada
 	sync_file_range$(EXEEXT) sync_file_range2$(EXEEXT) \
c5cada
-	sysinfo$(EXEEXT) syslog$(EXEEXT) tee$(EXEEXT) time$(EXEEXT) \
c5cada
-	timer_create$(EXEEXT) timer_xettime$(EXEEXT) \
c5cada
+	sysinfo$(EXEEXT) syslog$(EXEEXT) tee$(EXEEXT) tgkill$(EXEEXT) \
c5cada
+	time$(EXEEXT) timer_create$(EXEEXT) timer_xettime$(EXEEXT) \
c5cada
 	timerfd_xettime$(EXEEXT) times$(EXEEXT) times-fail$(EXEEXT) \
c5cada
 	tkill$(EXEEXT) truncate$(EXEEXT) truncate64$(EXEEXT) \
c5cada
 	ugetrlimit$(EXEEXT) uio$(EXEEXT) umask$(EXEEXT) \
c5cada
@@ -3444,6 +3444,10 @@
c5cada
 tee_OBJECTS = tee.$(OBJEXT)
c5cada
 tee_LDADD = $(LDADD)
c5cada
 tee_DEPENDENCIES = libtests.a
c5cada
+tgkill_SOURCES = tgkill.c
c5cada
+tgkill_OBJECTS = tgkill.$(OBJEXT)
c5cada
+tgkill_LDADD = $(LDADD)
c5cada
+tgkill_DEPENDENCIES = libtests.a
c5cada
 threads_execve_SOURCES = threads-execve.c
c5cada
 threads_execve_OBJECTS = threads-execve.$(OBJEXT)
c5cada
 threads_execve_DEPENDENCIES = $(am__DEPENDENCIES_1) $(LDADD)
c5cada
@@ -4181,7 +4185,7 @@
c5cada
 	./$(DEPDIR)/symlinkat.Po ./$(DEPDIR)/sync.Po \
c5cada
 	./$(DEPDIR)/sync_file_range.Po ./$(DEPDIR)/sync_file_range2.Po \
c5cada
 	./$(DEPDIR)/sysinfo.Po ./$(DEPDIR)/syslog-success.Po \
c5cada
-	./$(DEPDIR)/syslog.Po ./$(DEPDIR)/tee.Po \
c5cada
+	./$(DEPDIR)/syslog.Po ./$(DEPDIR)/tee.Po ./$(DEPDIR)/tgkill.Po \
c5cada
 	./$(DEPDIR)/threads-execve--quiet-thread-execve.Po \
c5cada
 	./$(DEPDIR)/threads-execve-q.Po \
c5cada
 	./$(DEPDIR)/threads-execve-qq.Po \
c5cada
@@ -4443,7 +4447,7 @@
c5cada
 	strace--strings-in-hex-non-ascii.c strace-x.c strace-xx.c \
c5cada
 	swap.c sxetmask.c symlink.c symlinkat.c sync.c \
c5cada
 	sync_file_range.c sync_file_range2.c sysinfo.c syslog.c \
c5cada
-	syslog-success.c tee.c threads-execve.c \
c5cada
+	syslog-success.c tee.c tgkill.c threads-execve.c \
c5cada
 	threads-execve--quiet-thread-execve.c threads-execve-q.c \
c5cada
 	threads-execve-qq.c threads-execve-qqq.c time.c timer_create.c \
c5cada
 	timer_xettime.c timerfd_xettime.c times.c times-fail.c tkill.c \
c5cada
@@ -4669,7 +4673,7 @@
c5cada
 	strace--strings-in-hex-non-ascii.c strace-x.c strace-xx.c \
c5cada
 	swap.c sxetmask.c symlink.c symlinkat.c sync.c \
c5cada
 	sync_file_range.c sync_file_range2.c sysinfo.c syslog.c \
c5cada
-	syslog-success.c tee.c threads-execve.c \
c5cada
+	syslog-success.c tee.c tgkill.c threads-execve.c \
c5cada
 	threads-execve--quiet-thread-execve.c threads-execve-q.c \
c5cada
 	threads-execve-qq.c threads-execve-qqq.c time.c timer_create.c \
c5cada
 	timer_xettime.c timerfd_xettime.c times.c times-fail.c tkill.c \
c5cada
@@ -5724,6 +5728,7 @@
c5cada
   sysinfo \
c5cada
   syslog \
c5cada
   tee \
c5cada
+  tgkill \
c5cada
   time \
c5cada
   timer_create \
c5cada
   timer_xettime \
c5cada
@@ -6133,7 +6138,7 @@
c5cada
 	strace-xx.gen.test swap.gen.test sxetmask.gen.test \
c5cada
 	symlink.gen.test symlinkat.gen.test sync.gen.test \
c5cada
 	sync_file_range.gen.test sync_file_range2.gen.test \
c5cada
-	sysinfo.gen.test syslog.gen.test tee.gen.test \
c5cada
+	sysinfo.gen.test syslog.gen.test tee.gen.test tgkill.gen.test \
c5cada
 	threads-execve--quiet-thread-execve.gen.test \
c5cada
 	threads-execve-q.gen.test threads-execve-qq.gen.test \
c5cada
 	threads-execve-qqq.gen.test time.gen.test \
c5cada
@@ -9355,6 +9360,10 @@
c5cada
 	@rm -f tee$(EXEEXT)
c5cada
 	$(AM_V_CCLD)$(LINK) $(tee_OBJECTS) $(tee_LDADD) $(LIBS)
c5cada
 
c5cada
+tgkill$(EXEEXT): $(tgkill_OBJECTS) $(tgkill_DEPENDENCIES) $(EXTRA_tgkill_DEPENDENCIES) 
c5cada
+	@rm -f tgkill$(EXEEXT)
c5cada
+	$(AM_V_CCLD)$(LINK) $(tgkill_OBJECTS) $(tgkill_LDADD) $(LIBS)
c5cada
+
c5cada
 threads-execve$(EXEEXT): $(threads_execve_OBJECTS) $(threads_execve_DEPENDENCIES) $(EXTRA_threads_execve_DEPENDENCIES) 
c5cada
 	@rm -f threads-execve$(EXEEXT)
c5cada
 	$(AM_V_CCLD)$(LINK) $(threads_execve_OBJECTS) $(threads_execve_LDADD) $(LIBS)
c5cada
@@ -10349,6 +10358,7 @@
c5cada
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/syslog-success.Po@am__quote@ # am--include-marker
c5cada
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/syslog.Po@am__quote@ # am--include-marker
c5cada
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tee.Po@am__quote@ # am--include-marker
c5cada
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tgkill.Po@am__quote@ # am--include-marker
c5cada
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/threads-execve--quiet-thread-execve.Po@am__quote@ # am--include-marker
c5cada
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/threads-execve-q.Po@am__quote@ # am--include-marker
c5cada
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/threads-execve-qq.Po@am__quote@ # am--include-marker
c5cada
@@ -12170,6 +12180,7 @@
c5cada
 	-rm -f ./$(DEPDIR)/syslog-success.Po
c5cada
 	-rm -f ./$(DEPDIR)/syslog.Po
c5cada
 	-rm -f ./$(DEPDIR)/tee.Po
c5cada
+	-rm -f ./$(DEPDIR)/tgkill.Po
c5cada
 	-rm -f ./$(DEPDIR)/threads-execve--quiet-thread-execve.Po
c5cada
 	-rm -f ./$(DEPDIR)/threads-execve-q.Po
c5cada
 	-rm -f ./$(DEPDIR)/threads-execve-qq.Po
c5cada
@@ -13026,6 +13037,7 @@
c5cada
 	-rm -f ./$(DEPDIR)/syslog-success.Po
c5cada
 	-rm -f ./$(DEPDIR)/syslog.Po
c5cada
 	-rm -f ./$(DEPDIR)/tee.Po
c5cada
+	-rm -f ./$(DEPDIR)/tgkill.Po
c5cada
 	-rm -f ./$(DEPDIR)/threads-execve--quiet-thread-execve.Po
c5cada
 	-rm -f ./$(DEPDIR)/threads-execve-q.Po
c5cada
 	-rm -f ./$(DEPDIR)/threads-execve-qq.Po
c5cada
@@ -15085,6 +15097,9 @@
c5cada
 $(srcdir)/tee.gen.test: $(abs_srcdir)/gen_tests.sh $(srcdir)/gen_tests.in
c5cada
 	$(AM_V_GEN) $^ $@
c5cada
 
c5cada
+$(srcdir)/tgkill.gen.test: $(abs_srcdir)/gen_tests.sh $(srcdir)/gen_tests.in
c5cada
+	$(AM_V_GEN) $^ $@
c5cada
+
c5cada
 $(srcdir)/threads-execve--quiet-thread-execve.gen.test: $(abs_srcdir)/gen_tests.sh $(srcdir)/gen_tests.in
c5cada
 	$(AM_V_GEN) $^ $@
c5cada
 
c5cada
Index: strace-5.7/tests/Makefile.in
c5cada
===================================================================
c5cada
--- strace-5.7.orig/tests/Makefile.in	2020-09-09 19:30:36.780885588 +0200
c5cada
+++ strace-5.7/tests/Makefile.in	2020-09-09 19:46:24.904450714 +0200
c5cada
@@ -493,8 +493,8 @@
c5cada
 	strace-xx$(EXEEXT) swap$(EXEEXT) sxetmask$(EXEEXT) \
c5cada
 	symlink$(EXEEXT) symlinkat$(EXEEXT) sync$(EXEEXT) \
c5cada
 	sync_file_range$(EXEEXT) sync_file_range2$(EXEEXT) \
c5cada
-	sysinfo$(EXEEXT) syslog$(EXEEXT) tee$(EXEEXT) time$(EXEEXT) \
c5cada
-	timer_create$(EXEEXT) timer_xettime$(EXEEXT) \
c5cada
+	sysinfo$(EXEEXT) syslog$(EXEEXT) tee$(EXEEXT) tgkill$(EXEEXT) \
c5cada
+	time$(EXEEXT) timer_create$(EXEEXT) timer_xettime$(EXEEXT) \
c5cada
 	timerfd_xettime$(EXEEXT) times$(EXEEXT) times-fail$(EXEEXT) \
c5cada
 	tkill$(EXEEXT) truncate$(EXEEXT) truncate64$(EXEEXT) \
c5cada
 	ugetrlimit$(EXEEXT) uio$(EXEEXT) umask$(EXEEXT) \
c5cada
@@ -3444,6 +3444,10 @@
c5cada
 tee_OBJECTS = tee.$(OBJEXT)
c5cada
 tee_LDADD = $(LDADD)
c5cada
 tee_DEPENDENCIES = libtests.a
c5cada
+tgkill_SOURCES = tgkill.c
c5cada
+tgkill_OBJECTS = tgkill.$(OBJEXT)
c5cada
+tgkill_LDADD = $(LDADD)
c5cada
+tgkill_DEPENDENCIES = libtests.a
c5cada
 threads_execve_SOURCES = threads-execve.c
c5cada
 threads_execve_OBJECTS = threads-execve.$(OBJEXT)
c5cada
 threads_execve_DEPENDENCIES = $(am__DEPENDENCIES_1) $(LDADD)
c5cada
@@ -4181,7 +4185,7 @@
c5cada
 	./$(DEPDIR)/symlinkat.Po ./$(DEPDIR)/sync.Po \
c5cada
 	./$(DEPDIR)/sync_file_range.Po ./$(DEPDIR)/sync_file_range2.Po \
c5cada
 	./$(DEPDIR)/sysinfo.Po ./$(DEPDIR)/syslog-success.Po \
c5cada
-	./$(DEPDIR)/syslog.Po ./$(DEPDIR)/tee.Po \
c5cada
+	./$(DEPDIR)/syslog.Po ./$(DEPDIR)/tee.Po ./$(DEPDIR)/tgkill.Po \
c5cada
 	./$(DEPDIR)/threads-execve--quiet-thread-execve.Po \
c5cada
 	./$(DEPDIR)/threads-execve-q.Po \
c5cada
 	./$(DEPDIR)/threads-execve-qq.Po \
c5cada
@@ -4443,7 +4447,7 @@
c5cada
 	strace--strings-in-hex-non-ascii.c strace-x.c strace-xx.c \
c5cada
 	swap.c sxetmask.c symlink.c symlinkat.c sync.c \
c5cada
 	sync_file_range.c sync_file_range2.c sysinfo.c syslog.c \
c5cada
-	syslog-success.c tee.c threads-execve.c \
c5cada
+	syslog-success.c tee.c tgkill.c threads-execve.c \
c5cada
 	threads-execve--quiet-thread-execve.c threads-execve-q.c \
c5cada
 	threads-execve-qq.c threads-execve-qqq.c time.c timer_create.c \
c5cada
 	timer_xettime.c timerfd_xettime.c times.c times-fail.c tkill.c \
c5cada
@@ -4669,7 +4673,7 @@
c5cada
 	strace--strings-in-hex-non-ascii.c strace-x.c strace-xx.c \
c5cada
 	swap.c sxetmask.c symlink.c symlinkat.c sync.c \
c5cada
 	sync_file_range.c sync_file_range2.c sysinfo.c syslog.c \
c5cada
-	syslog-success.c tee.c threads-execve.c \
c5cada
+	syslog-success.c tee.c tgkill.c threads-execve.c \
c5cada
 	threads-execve--quiet-thread-execve.c threads-execve-q.c \
c5cada
 	threads-execve-qq.c threads-execve-qqq.c time.c timer_create.c \
c5cada
 	timer_xettime.c timerfd_xettime.c times.c times-fail.c tkill.c \
c5cada
@@ -5724,6 +5728,7 @@
c5cada
   sysinfo \
c5cada
   syslog \
c5cada
   tee \
c5cada
+  tgkill \
c5cada
   time \
c5cada
   timer_create \
c5cada
   timer_xettime \
c5cada
@@ -6133,7 +6138,7 @@
c5cada
 	strace-xx.gen.test swap.gen.test sxetmask.gen.test \
c5cada
 	symlink.gen.test symlinkat.gen.test sync.gen.test \
c5cada
 	sync_file_range.gen.test sync_file_range2.gen.test \
c5cada
-	sysinfo.gen.test syslog.gen.test tee.gen.test \
c5cada
+	sysinfo.gen.test syslog.gen.test tee.gen.test tgkill.gen.test \
c5cada
 	threads-execve--quiet-thread-execve.gen.test \
c5cada
 	threads-execve-q.gen.test threads-execve-qq.gen.test \
c5cada
 	threads-execve-qqq.gen.test time.gen.test \
c5cada
@@ -9355,6 +9360,10 @@
c5cada
 	@rm -f tee$(EXEEXT)
c5cada
 	$(AM_V_CCLD)$(LINK) $(tee_OBJECTS) $(tee_LDADD) $(LIBS)
c5cada
 
c5cada
+tgkill$(EXEEXT): $(tgkill_OBJECTS) $(tgkill_DEPENDENCIES) $(EXTRA_tgkill_DEPENDENCIES) 
c5cada
+	@rm -f tgkill$(EXEEXT)
c5cada
+	$(AM_V_CCLD)$(LINK) $(tgkill_OBJECTS) $(tgkill_LDADD) $(LIBS)
c5cada
+
c5cada
 threads-execve$(EXEEXT): $(threads_execve_OBJECTS) $(threads_execve_DEPENDENCIES) $(EXTRA_threads_execve_DEPENDENCIES) 
c5cada
 	@rm -f threads-execve$(EXEEXT)
c5cada
 	$(AM_V_CCLD)$(LINK) $(threads_execve_OBJECTS) $(threads_execve_LDADD) $(LIBS)
c5cada
@@ -10349,6 +10358,7 @@
c5cada
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/syslog-success.Po@am__quote@ # am--include-marker
c5cada
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/syslog.Po@am__quote@ # am--include-marker
c5cada
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tee.Po@am__quote@ # am--include-marker
c5cada
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tgkill.Po@am__quote@ # am--include-marker
c5cada
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/threads-execve--quiet-thread-execve.Po@am__quote@ # am--include-marker
c5cada
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/threads-execve-q.Po@am__quote@ # am--include-marker
c5cada
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/threads-execve-qq.Po@am__quote@ # am--include-marker
c5cada
@@ -12170,6 +12180,7 @@
c5cada
 	-rm -f ./$(DEPDIR)/syslog-success.Po
c5cada
 	-rm -f ./$(DEPDIR)/syslog.Po
c5cada
 	-rm -f ./$(DEPDIR)/tee.Po
c5cada
+	-rm -f ./$(DEPDIR)/tgkill.Po
c5cada
 	-rm -f ./$(DEPDIR)/threads-execve--quiet-thread-execve.Po
c5cada
 	-rm -f ./$(DEPDIR)/threads-execve-q.Po
c5cada
 	-rm -f ./$(DEPDIR)/threads-execve-qq.Po
c5cada
@@ -13026,6 +13037,7 @@
c5cada
 	-rm -f ./$(DEPDIR)/syslog-success.Po
c5cada
 	-rm -f ./$(DEPDIR)/syslog.Po
c5cada
 	-rm -f ./$(DEPDIR)/tee.Po
c5cada
+	-rm -f ./$(DEPDIR)/tgkill.Po
c5cada
 	-rm -f ./$(DEPDIR)/threads-execve--quiet-thread-execve.Po
c5cada
 	-rm -f ./$(DEPDIR)/threads-execve-q.Po
c5cada
 	-rm -f ./$(DEPDIR)/threads-execve-qq.Po
c5cada
@@ -15085,6 +15097,9 @@
c5cada
 $(srcdir)/tee.gen.test: $(abs_srcdir)/gen_tests.sh $(srcdir)/gen_tests.in
c5cada
 	$(AM_V_GEN) $^ $@
c5cada
 
c5cada
+$(srcdir)/tgkill.gen.test: $(abs_srcdir)/gen_tests.sh $(srcdir)/gen_tests.in
c5cada
+	$(AM_V_GEN) $^ $@
c5cada
+
c5cada
 $(srcdir)/threads-execve--quiet-thread-execve.gen.test: $(abs_srcdir)/gen_tests.sh $(srcdir)/gen_tests.in
c5cada
 	$(AM_V_GEN) $^ $@
c5cada