From ac8399db6ce846597966360732ce6d39a247bdd2 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Mon, 6 May 2024 04:25:51 +0200 Subject: Adding debian version 241-7~deb10u8. Signed-off-by: Daniel Baumann --- debian/udev.preinst | 81 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 81 insertions(+) create mode 100644 debian/udev.preinst (limited to 'debian/udev.preinst') diff --git a/debian/udev.preinst b/debian/udev.preinst new file mode 100644 index 0000000..b24d9da --- /dev/null +++ b/debian/udev.preinst @@ -0,0 +1,81 @@ +#!/bin/sh -e + +# adapted from postinst +chrooted() { + if [ "$(stat -c %d/%i /)" = "$(stat -Lc %d/%i /proc/1/root 2>/dev/null)" ]; + then + return 1 + fi + return 0 +} + +check_kernel_features() { + # skip the check if udev is not already active + [ -d /run/udev/ ] || return 0 + + if [ -e /proc/kallsyms ]; then + + local needed_symbols='inotify_init signalfd accept4 open_by_handle_at timerfd_create epoll_create' + for symbol in $needed_symbols; do + if ! egrep -q "^[a-fA-F0-9]+ T \.?sys_${symbol}$" /proc/kallsyms; then + cat <