diff options
author | Etienne Dechamps <[email protected]> | 2012-07-17 10:36:43 +0200 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2012-07-26 13:40:18 -0700 |
commit | 319a99a3d440480fe9c37f637cb9cac8e0f20ded (patch) | |
tree | 22d62c05e2edde3e334484e2a0a8a0b4b2470b63 /config/zfs-build.m4 | |
parent | b2c5198b1996c9053c1bae38755f76125c8cb169 (diff) |
Make configure builtin-aware.
This patch adds a new option to configure: --enable-linux-builtin. When
this option is used, the following happens:
- Compilation of kernel modules is disabled.
- A failure to find UTS_RELEASE is followed by a suggestion to run
"make prepare" on the kernel source tree.
This patch also adds a new test which tries to compile an empty module
as a basic toolchain sanity test. If it fails and the option was
specified, the error is followed by a suggestion to run "make scripts"
on the kernel source tree.
Signed-off-by: Prakash Surya <[email protected]>
Signed-off-by: Brian Behlendorf <[email protected]>
Issue #851
Diffstat (limited to 'config/zfs-build.m4')
-rw-r--r-- | config/zfs-build.m4 | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/config/zfs-build.m4 b/config/zfs-build.m4 index 6bfea5195..8e6b13b24 100644 --- a/config/zfs-build.m4 +++ b/config/zfs-build.m4 @@ -73,6 +73,11 @@ AC_DEFUN([ZFS_AC_CONFIG], [ AS_HELP_STRING([--with-config=CONFIG], [Config file 'kernel|user|all|srpm']), [ZFS_CONFIG="$withval"]) + AC_ARG_ENABLE([linux-builtin], + [AC_HELP_STRING([--enable-linux-builtin], + [Configure for builtin in-tree kernel modules @<:@default=no@:>@])], + [], + [enable_linux_builtin=no]) AC_MSG_CHECKING([zfs config]) AC_MSG_RESULT([$ZFS_CONFIG]); @@ -93,11 +98,10 @@ AC_DEFUN([ZFS_AC_CONFIG], [ esac AM_CONDITIONAL([CONFIG_USER], - [test "$ZFS_CONFIG" = user] || - [test "$ZFS_CONFIG" = all]) + [test "$ZFS_CONFIG" = user -o "$ZFS_CONFIG" = all]) AM_CONDITIONAL([CONFIG_KERNEL], - [test "$ZFS_CONFIG" = kernel] || - [test "$ZFS_CONFIG" = all]) + [test "$ZFS_CONFIG" = kernel -o "$ZFS_CONFIG" = all] && + [test "x$enable_linux_builtin" != xyes ]) ]) dnl # |