diff options
author | David Disseldorp <ddiss@samba.org> | 2014-02-15 10:37:28 +0100 |
---|---|---|
committer | Andreas Schneider <asn@samba.org> | 2014-02-19 18:22:29 +0100 |
commit | 8524cf69d683107a488945bf39c55ceb57ed19a9 (patch) | |
tree | 836eab1cec527238961c6e0930e12499cb6709e5 | |
parent | 8dc6f0fb39647e37a444ac582b5b33e27b40b3dc (diff) | |
download | samba-8524cf69d683107a488945bf39c55ceb57ed19a9.tar.gz samba-8524cf69d683107a488945bf39c55ceb57ed19a9.tar.xz samba-8524cf69d683107a488945bf39c55ceb57ed19a9.zip |
build: use configure var for libarchive depenency
Avoid CONFIG_SET('HAVE_LIBARCHIVE') checks in wscript_build, by using a
simple archive_lib variable.
Signed-off-by: David Disseldorp <ddiss@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
-rw-r--r-- | source3/wscript | 4 | ||||
-rwxr-xr-x | source3/wscript_build | 3 |
2 files changed, 4 insertions, 3 deletions
diff --git a/source3/wscript b/source3/wscript index 39ab1f335c6..99ec1beb8db 100644 --- a/source3/wscript +++ b/source3/wscript @@ -196,10 +196,12 @@ main() { # check for libarchive (tar command in smbclient) # None means autodetect, True/False means enable/disable + conf.env['archive_lib'] = '' if Options.options.with_libarchive is not False: libarchive_mandatory = Options.options.with_libarchive == True Logs.info("Checking for libarchive existence") - conf.CHECK_LIB('archive', mandatory=libarchive_mandatory) + if conf.CHECK_LIB('archive', mandatory=libarchive_mandatory): + conf.env['archive_lib'] = 'archive' if not conf.CHECK_HEADERS('archive.h') and libarchive_mandatory: conf.fatal('libarchive support requested, but no suitable header found') diff --git a/source3/wscript_build b/source3/wscript_build index 9265e00c395..9d3071a74cd 100755 --- a/source3/wscript_build +++ b/source3/wscript_build @@ -1005,8 +1005,7 @@ bld.SAMBA3_BINARY('client/smbclient', msrpc3 RPC_NDR_SRVSVC cli_smb_common - '''+ - ('archive' if bld.CONFIG_SET('HAVE_LIBARCHIVE') else '')) + ''' + bld.env['archive_lib']) bld.SAMBA3_BINARY('net', source='''utils/net.c |