kernel: Remove more stray backslash in grep regex and move path_umount as optional backport
This commit is contained in:
@@ -32,11 +32,6 @@ $(warning "KSU_GIT_VERSION not defined! It is better to make SukiSU a git submod
|
|||||||
ccflags-y += -DKSU_VERSION=12800
|
ccflags-y += -DKSU_VERSION=12800
|
||||||
endif
|
endif
|
||||||
|
|
||||||
# Do checks before compile
|
|
||||||
ifeq ($(shell grep -q "int\s\+path_umount" $(srctree)/fs/namespace.c; echo $$?),0)
|
|
||||||
ccflags-y += -DKSU_HAS_PATH_UMOUNT
|
|
||||||
endif
|
|
||||||
|
|
||||||
# Checks hooks state
|
# Checks hooks state
|
||||||
ifeq ($(strip $(CONFIG_KSU_MANUAL_HOOK)),y)
|
ifeq ($(strip $(CONFIG_KSU_MANUAL_HOOK)),y)
|
||||||
$(info -- KernelSU: Manually-patched hook.)
|
$(info -- KernelSU: Manually-patched hook.)
|
||||||
@@ -57,10 +52,10 @@ endif
|
|||||||
ifeq ($(shell grep -q "get_cred_rcu" $(srctree)/include/linux/cred.h; echo $$?),0)
|
ifeq ($(shell grep -q "get_cred_rcu" $(srctree)/include/linux/cred.h; echo $$?),0)
|
||||||
ccflags-y += -DKSU_COMPAT_HAS_GET_CRED_RCU
|
ccflags-y += -DKSU_COMPAT_HAS_GET_CRED_RCU
|
||||||
else
|
else
|
||||||
ifeq ($(shell grep -q "atomic_long_t\s\+\usage" $(srctree)/include/linux/cred.h; echo $$?),0)
|
ifeq ($(shell grep -q "atomic_long_t\s\+usage" $(srctree)/include/linux/cred.h; echo $$?),0)
|
||||||
ccflags-y += -DKSU_COMPAT_ATOMIC_LONG
|
ccflags-y += -DKSU_COMPAT_ATOMIC_LONG
|
||||||
endif
|
endif
|
||||||
ifeq ($(shell grep -q "int\s\+\non_rcu" $(srctree)/include/linux/cred.h; echo $$?),0)
|
ifeq ($(shell grep -q "int\s\+non_rcu" $(srctree)/include/linux/cred.h; echo $$?),0)
|
||||||
ccflags-y += -DKSU_COMPAT_HAS_NONCONST_CRED
|
ccflags-y += -DKSU_COMPAT_HAS_NONCONST_CRED
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
@@ -75,6 +70,9 @@ endif
|
|||||||
ifeq ($(shell grep "ssize_t kernel_write" $(srctree)/fs/read_write.c | grep -q "const void" ; echo $$?),0)
|
ifeq ($(shell grep "ssize_t kernel_write" $(srctree)/fs/read_write.c | grep -q "const void" ; echo $$?),0)
|
||||||
ccflags-y += -DKSU_OPTIONAL_KERNEL_WRITE
|
ccflags-y += -DKSU_OPTIONAL_KERNEL_WRITE
|
||||||
endif
|
endif
|
||||||
|
ifeq ($(shell grep -q "int\s\+path_umount" $(srctree)/fs/namespace.c; echo $$?),0)
|
||||||
|
ccflags-y += -DKSU_HAS_PATH_UMOUNT
|
||||||
|
endif
|
||||||
|
|
||||||
# Checks Samsung UH drivers
|
# Checks Samsung UH drivers
|
||||||
ifeq ($(shell grep -q "CONFIG_KDP_CRED" $(srctree)/kernel/cred.c; echo $$?),0)
|
ifeq ($(shell grep -q "CONFIG_KDP_CRED" $(srctree)/kernel/cred.c; echo $$?),0)
|
||||||
|
|||||||
Reference in New Issue
Block a user