summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2018-05-10 13:04:35 +1200
committerAndrew Bartlett <abartlet@samba.org>2018-05-15 03:36:08 +0200
commit78c8e699a8e34ebe69b704b455733050fd195af6 (patch)
treea43abd80541ad132824f23f5c963753847965217 /source3
parent6fda57d3097e4e02310d7cfdba4f8ee27a69fb93 (diff)
downloadsamba-78c8e699a8e34ebe69b704b455733050fd195af6.tar.gz
build: Make --with-libarchive the default
This means that those not wanting to link to libarchive will just need to build --without-libarchive. In general, we prefer that optional libraries be required by default so that they are not accidentially missed, particularly in packages. Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Gary Lockyer <gary@catalyst.net.nz>
Diffstat (limited to 'source3')
-rw-r--r--source3/client/clitar.c2
-rw-r--r--source3/wscript12
2 files changed, 9 insertions, 5 deletions
diff --git a/source3/client/clitar.c b/source3/client/clitar.c
index b8009c92cb6..b598bde4ee8 100644
--- a/source3/client/clitar.c
+++ b/source3/client/clitar.c
@@ -1837,7 +1837,7 @@ static NTSTATUS path_base_name(TALLOC_CTX *ctx, const char *path, char **_base)
#else
-#define NOT_IMPLEMENTED DEBUG(0, ("tar mode not compiled. build with --with-libarchive\n"))
+#define NOT_IMPLEMENTED DEBUG(0, ("tar mode not compiled. build used --without-libarchive\n"))
int cmd_block(void)
{
diff --git a/source3/wscript b/source3/wscript
index e6d9936fb16..7a1c579ef67 100644
--- a/source3/wscript
+++ b/source3/wscript
@@ -55,7 +55,7 @@ def set_options(opt):
opt.SAMBA3_ADD_OPTION('dmapi', default=None) # None means autodetection
opt.SAMBA3_ADD_OPTION('fam', default=None) # None means autodetection
opt.SAMBA3_ADD_OPTION('profiling-data', default=False)
- opt.SAMBA3_ADD_OPTION('libarchive', default=None)
+ opt.SAMBA3_ADD_OPTION('libarchive', default=True)
opt.SAMBA3_ADD_OPTION('cluster-support', default=False)
@@ -218,12 +218,16 @@ main() {
# None means autodetect, True/False means enable/disable
conf.SET_TARGET_TYPE('archive', 'EMPTY')
if Options.options.with_libarchive is not False:
- libarchive_mandatory = Options.options.with_libarchive == True
Logs.info("Checking for libarchive existence")
if conf.CHECK_HEADERS('archive.h') and conf.CHECK_LIB('archive', shlib=True):
conf.CHECK_FUNCS_IN('archive_read_support_filter_all archive_read_free', 'archive')
- elif libarchive_mandatory:
- conf.fatal('libarchive support requested, but not found')
+ else:
+ conf.fatal("libarchive support not found. "
+ "Try installing libarchive-dev or libarchive-devel. "
+ "Otherwise, use --without-libarchive to "
+ "build without libarchive support. "
+ "libarchive support is required for the smbclient "
+ "tar-file mode")
# check for DMAPI libs
if Options.options.with_dmapi == False: