File: kernel-kasan-enabled.m4

package info (click to toggle)
zfs-linux 2.4.1-1
  • links: PTS, VCS
  • area: contrib
  • in suites: forky, sid
  • size: 71,788 kB
  • sloc: ansic: 398,467; sh: 70,894; asm: 48,745; python: 8,163; makefile: 5,220; perl: 859
file content (23 lines) | stat: -rw-r--r-- 685 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
dnl #
dnl # 6.18: some architectures and config option causes the kasan_ inline
dnl #       functions to reference the GPL-only symbol 'kasan_flag_enabled',
dnl #       breaking the build. Detect this and work
dnl #       around it.
AC_DEFUN([ZFS_AC_KERNEL_SRC_KASAN_ENABLED], [
	ZFS_LINUX_TEST_SRC([kasan_enabled], [
		#include <linux/kasan.h>
	], [
		kasan_enabled();
	], [], [ZFS_META_LICENSE])
])
AC_DEFUN([ZFS_AC_KERNEL_KASAN_ENABLED], [
	AC_MSG_CHECKING([whether kasan_enabled() is GPL-only])
	ZFS_LINUX_TEST_RESULT([kasan_enabled_license], [
		AC_MSG_RESULT(no)
	], [
		AC_MSG_RESULT(yes)
		AC_DEFINE(HAVE_KASAN_ENABLED_GPL_ONLY, 1,
		    [kasan_enabled() is GPL-only])
	])
])