From 8e43b2d64d7f13d211212dd44fda573bf4cad596 Mon Sep 17 00:00:00 2001 From: ShirkNeko <109797057+ShirkNeko@users.noreply.github.com> Date: Sat, 20 Sep 2025 13:30:34 +0800 Subject: [PATCH] makefile: Checking support for proc_ops in the kernel --- kernel/Makefile | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/kernel/Makefile b/kernel/Makefile index 4e377e52..0dfe0138 100644 --- a/kernel/Makefile +++ b/kernel/Makefile @@ -150,6 +150,11 @@ $(info -- KernelSU/compat: new vfs_getattr() found) ccflags-y += -DKSU_HAS_NEW_VFS_GETATTR endif +# Function proc_ops check +ifeq ($(shell grep -q "struct proc_ops " $(srctree)/include/linux/proc_fs.h; echo $$?),0) +ccflags-y += -DKSU_COMPAT_HAS_PROC_OPS +endif + # Custom Signs ifdef KSU_EXPECTED_SIZE ccflags-y += -DEXPECTED_SIZE=$(KSU_EXPECTED_SIZE) @@ -181,8 +186,4 @@ $(info -- You have not integrated susfs in your kernel yet.) $(info -- Read: https://gitlab.com/simonpunk/susfs4ksu) endif -# Function proc_ops check -ifeq ($(shell grep -q "struct proc_ops " $(srctree)/include/linux/proc_fs.h; echo $$?),0) -ccflags-y += -DKSU_COMPAT_HAS_PROC_OPS -endif # Keep a new line here!! Because someone may append config