criu/scripts
Alexander Mikhalitsyn e30d18f435 rseq: fix headers conflict on Mariner GNU/Linux
1. For some reason, Marier distribution headers
not correctly define __GLIBC_HAVE_KERNEL_RSEQ
compile-time constant. It remains undefined,
but in fact header files provides corresponding
rseq types declaration which leads to conflict.

2. Another issue, is that they use uint*_t types
instead of __u* types as in original rseq.h.

This leads to compile time issues like this:
format '%llx' expects argument of type 'long long unsigned int', but argument 5 has type 'uint64_t' {aka 'long unsigned int'}

and we can't even replace %llx to %PRIx64 because it will break
compilation on other distros (like Fedora) with analogical error:

error: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 6 has type ‘__u64’ {aka ‘long long unsigned int’}

Let's use our-own struct rseq copy fully equal to the kernel one,
it's safe because this structure is a part of Linux Kernel ABI.

Fixes #1934

Reported-by: Nikola Bojanic
Signed-off-by: Alexander Mikhalitsyn <alexander.mikhalitsyn@virtuozzo.com>
2023-04-15 21:17:21 -07:00
..
build Revert "test: disable rseq also on Archlinux" 2022-04-28 17:53:52 -07:00
ci Add --skip-file-rwx-check opt test 2023-04-15 21:17:21 -07:00
nmk Fix some codespell warnings 2022-04-28 17:53:52 -07:00
crit-setup.py crit: Use same version as criu 2022-06-22 10:20:33 -07:00
criu-ns Fix the check for mnt namespace in criu-ns 2023-04-15 21:17:21 -07:00
fake-restore.sh zdtm: check an exit code of a straced restore 2018-05-12 11:45:31 +03:00
feature-tests.mak rseq: fix headers conflict on Mariner GNU/Linux 2023-04-15 21:17:21 -07:00
fetch-clang-format.sh clang-format: enable AlignTrailingComments 2022-04-28 17:53:52 -07:00
flake8.cfg coredump: remove unused import 2022-04-28 17:53:52 -07:00
install-criu-image-streamer.sh scripts: run shellcheck on the scripts folder 2020-10-20 00:18:24 -07:00
install-debian-pkgs.sh scripts: run shellcheck on the scripts folder 2020-10-20 00:18:24 -07:00
magic-gen.py py: Fix tabs in code comments 2019-09-07 15:59:57 +03:00
protobuf-gen.sh scripts: run shellcheck on the scripts folder 2020-10-20 00:18:24 -07:00
systemd-autofs-restart.sh Fix some codespell warnings 2022-04-28 17:53:52 -07:00
tmp-files.sh scripts: fix shellcheck warnings 2021-09-03 10:31:00 -07:00