[PATCH] build: support configure --without-btrfs

David Disseldorp ddiss at samba.org
Fri May 16 10:01:09 MDT 2014


Thanks to Kai's great SambaXP micro-server scaling talk for the
inspiration.

Signed-off-by: David Disseldorp <ddiss at samba.org>
---
 source3/wscript | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/source3/wscript b/source3/wscript
index 2bca8fa..107ce11 100644
--- a/source3/wscript
+++ b/source3/wscript
@@ -61,6 +61,7 @@ def set_options(opt):
                    action="store", dest='libcephfs_dir', default=None)
 
     opt.SAMBA3_ADD_OPTION('glusterfs', with_name="enable", without_name="disable", default=True)
+    opt.SAMBA3_ADD_OPTION('btrfs', default=None)
 
 
 def configure(conf):
@@ -1891,7 +1892,12 @@ main() {
     if conf.CONFIG_SET('HAVE_GPFS'):
 	default_shared_modules.extend(TO_LIST('vfs_gpfs'))
 
-    if conf.CONFIG_SET('HAVE_LINUX_IOCTL'):
+    if Options.options.with_btrfs == True:
+	if conf.CONFIG_SET('HAVE_LINUX_IOCTL'):
+	    default_shared_modules.extend(TO_LIST('vfs_btrfs'))
+	else:
+            conf.fatal("linux ioctl not available, but --with-btrfs was specified")
+    elif Options.options.with_btrfs is None and conf.CONFIG_SET('HAVE_LINUX_IOCTL'):
 	default_shared_modules.extend(TO_LIST('vfs_btrfs'))
 
     if conf.CONFIG_SET('SAMBA_FAM_LIBS'):
-- 
1.8.4.5



More information about the samba-technical mailing list