[SCM] Samba Shared Repository - branch master updated

Andrew Bartlett abartlet at samba.org
Tue May 15 04:32:02 UTC 2018


The branch, master has been updated
       via  a0f0350 selftest: Require libarchive for --enable-selftest
       via  aced401 build: Make --with-gpgme the default
       via  78c8e69 build: Make --with-libarchive the default
       via  6fda57d build: Make --with-json-audit the default
      from  171750e s3/wscript: remove test, that we do in lib/replace

https://git.samba.org/?p=samba.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit a0f0350252fb079d9ffec9b7f3589e97872688f9
Author: Andrew Bartlett <abartlet at samba.org>
Date:   Thu May 10 14:00:54 2018 +1200

    selftest: Require libarchive for --enable-selftest
    
    This avoids one more case where tests can go missing by removing the conditional.
    
    (Yes, this has happend for other tests in the past).
    
    Signed-off-by: Andrew Bartlett <abartlet at samba.org>
    Reviewed-by: Stefan Metzmacher <metze at samba.org>
    Reviewed-by: Gary Lockyer <gary at catalyst.net.nz>
    
    Autobuild-User(master): Andrew Bartlett <abartlet at samba.org>
    Autobuild-Date(master): Tue May 15 06:31:03 CEST 2018 on sn-devel-144

commit aced4017283e2614e80fb6f20fc85d3a284ad6c1
Author: Andrew Bartlett <abartlet at samba.org>
Date:   Thu May 10 13:05:56 2018 +1200

    build: Make --with-gpgme the default
    
    Those wishing to build without gpgme support need simply to build --without-gpgme
    
    This 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 at samba.org>
    Reviewed-by: Stefan Metzmacher <metze at samba.org>
    Reviewed-by: Gary Lockyer <gary at catalyst.net.nz>

commit 78c8e699a8e34ebe69b704b455733050fd195af6
Author: Andrew Bartlett <abartlet at samba.org>
Date:   Thu May 10 13:04:35 2018 +1200

    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 at samba.org>
    Reviewed-by: Stefan Metzmacher <metze at samba.org>
    Reviewed-by: Gary Lockyer <gary at catalyst.net.nz>

commit 6fda57d3097e4e02310d7cfdba4f8ee27a69fb93
Author: Andrew Bartlett <abartlet at samba.org>
Date:   Thu May 10 13:01:05 2018 +1200

    build: Make --with-json-audit the default
    
    Thanks to Rowland for a clear description of the behaviour for the smb.conf manpage.
    
    This means that those not wanting to link to libarchive will just need to
    build --without-json-audit.
    
    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 at samba.org>
    Reviewed-by: Stefan Metzmacher <metze at samba.org>
    Reviewed-by: Gary Lockyer <gary at catalyst.net.nz>

-----------------------------------------------------------------------

Summary of changes:
 auth/wscript                             | 12 +++++---
 docs-xml/smbdotconf/logging/loglevel.xml |  4 +--
 source3/client/clitar.c                  |  2 +-
 source3/selftest/tests.py                | 49 +++++++++++++++-----------------
 source3/wscript                          | 16 ++++++++---
 source4/dsdb/samdb/ldb_modules/wscript   | 17 +++++++----
 6 files changed, 57 insertions(+), 43 deletions(-)


Changeset truncated at 500 lines:

diff --git a/auth/wscript b/auth/wscript
index b81804e..7b2c65e 100644
--- a/auth/wscript
+++ b/auth/wscript
@@ -4,7 +4,7 @@ import Logs, Options, Utils
 import samba3
 
 def set_options(opt):
-    help = ("Build with JSON auth audit support (default=auto). "
+    help = ("Build with JSON auth audit support (default=True). "
             "This requires the jansson devel package.")
 
     opt.SAMBA3_ADD_OPTION('json-audit', default=None, help=(help))
@@ -20,9 +20,13 @@ def configure(conf):
             conf.CHECK_FUNCS_IN('json_object', 'jansson')
 
     if not conf.CONFIG_GET('HAVE_JSON_OBJECT'):
-        if Options.options.with_json_audit == True:
-            conf.fatal('JSON support requested, but no suitable jansson '
-                       'library found')
+        if Options.options.with_json_audit != False:
+            conf.fatal("JSON support not found. "
+                       "Try installing libjansson-dev or jansson-devel. "
+                       "Otherwise, use --without-json-audit to build without "
+                       "JSON support. "
+                       "JSON support is required for the JSON "
+                       "formatted audit log feature")
         if conf.CONFIG_GET('ENABLE_SELFTEST') and \
           (not Options.options.without_ad_dc):
             raise Utils.WafError('jansson JSON library required for '
diff --git a/docs-xml/smbdotconf/logging/loglevel.xml b/docs-xml/smbdotconf/logging/loglevel.xml
index d3b5c45..fae5c7b 100644
--- a/docs-xml/smbdotconf/logging/loglevel.xml
+++ b/docs-xml/smbdotconf/logging/loglevel.xml
@@ -49,8 +49,8 @@
     </itemizedlist>
 
     <para>Authentication and authorization audit information is logged
-    under the auth_audit, and if Samba is compiled against the jansson
-    JSON library, a JSON representation is logged under
+    under the auth_audit, and if Samba was not compiled with
+    --without-json-audit, a JSON representation is logged under
     auth_json_audit.</para>
 
     <para>Support is comprehensive for all authentication and authorisation
diff --git a/source3/client/clitar.c b/source3/client/clitar.c
index b8009c9..b598bde 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/selftest/tests.py b/source3/selftest/tests.py
index 5ebebb5..1e1f97e 100755
--- a/source3/selftest/tests.py
+++ b/source3/selftest/tests.py
@@ -54,7 +54,6 @@ try:
 finally:
     f.close()
 
-have_libarchive = ("HAVE_LIBARCHIVE" in config_hash)
 have_linux_kernel_oplocks = ("HAVE_KERNEL_OPLOCKS_LINUX" in config_hash)
 have_inotify = ("HAVE_INOTIFY" in config_hash)
 have_ldwrap = ("HAVE_LDWRAP" in config_hash)
@@ -295,31 +294,29 @@ for env in ["fileserver"]:
     # tar command tests
     #
 
-    # tar command enabled only if built with libarchive
-    if have_libarchive:
-        # Test smbclient/tarmode
-        plantestsuite("samba3.blackbox.smbclient_tarmode.NT1", env,
-                      [os.path.join(samba3srcdir, "script/tests/test_smbclient_tarmode.sh"),
-                       '$SERVER', '$SERVER_IP', '$USERNAME', '$PASSWORD',
-                       '$LOCAL_PATH/tarmode', '$PREFIX', smbclient3, configuration, "-mNT1"])
-        plantestsuite("samba3.blackbox.smbclient_tarmode.SMB3", env,
-                      [os.path.join(samba3srcdir, "script/tests/test_smbclient_tarmode.sh"),
-                       '$SERVER', '$SERVER_IP', '$USERNAME', '$PASSWORD',
-                       '$LOCAL_PATH/tarmode', '$PREFIX', smbclient3, configuration, "-mSMB3"])
-
-        # Test suite for new smbclient/tar with libarchive (GSoC 13)
-        plantestsuite("samba3.blackbox.smbclient_tar.NT1", env,
-                      [os.path.join(samba3srcdir, "script/tests/test_smbclient_tarmode.pl"),
-                       '-n', '$SERVER', '-i', '$SERVER_IP', '-s', 'tmp',
-                       '-u', '$USERNAME', '-p', '$PASSWORD', '-l', '$LOCAL_PATH/tarmode',
-                       '-d', '$PREFIX', '-b', smbclient3,
-                       '--subunit', '--', configuration, '-mNT1'])
-        plantestsuite("samba3.blackbox.smbclient_tar.SMB3", env,
-                      [os.path.join(samba3srcdir, "script/tests/test_smbclient_tarmode.pl"),
-                       '-n', '$SERVER', '-i', '$SERVER_IP', '-s', 'tmp',
-                       '-u', '$USERNAME', '-p', '$PASSWORD', '-l', '$LOCAL_PATH/tarmode',
-                       '-d', '$PREFIX', '-b', smbclient3,
-                       '--subunit', '--', configuration, '-mSMB3'])
+    # Test smbclient/tarmode
+    plantestsuite("samba3.blackbox.smbclient_tarmode.NT1", env,
+                  [os.path.join(samba3srcdir, "script/tests/test_smbclient_tarmode.sh"),
+                   '$SERVER', '$SERVER_IP', '$USERNAME', '$PASSWORD',
+                   '$LOCAL_PATH/tarmode', '$PREFIX', smbclient3, configuration, "-mNT1"])
+    plantestsuite("samba3.blackbox.smbclient_tarmode.SMB3", env,
+                  [os.path.join(samba3srcdir, "script/tests/test_smbclient_tarmode.sh"),
+                   '$SERVER', '$SERVER_IP', '$USERNAME', '$PASSWORD',
+                   '$LOCAL_PATH/tarmode', '$PREFIX', smbclient3, configuration, "-mSMB3"])
+
+    # Test suite for new smbclient/tar with libarchive (GSoC 13)
+    plantestsuite("samba3.blackbox.smbclient_tar.NT1", env,
+                  [os.path.join(samba3srcdir, "script/tests/test_smbclient_tarmode.pl"),
+                   '-n', '$SERVER', '-i', '$SERVER_IP', '-s', 'tmp',
+                   '-u', '$USERNAME', '-p', '$PASSWORD', '-l', '$LOCAL_PATH/tarmode',
+                   '-d', '$PREFIX', '-b', smbclient3,
+                   '--subunit', '--', configuration, '-mNT1'])
+    plantestsuite("samba3.blackbox.smbclient_tar.SMB3", env,
+                  [os.path.join(samba3srcdir, "script/tests/test_smbclient_tarmode.pl"),
+                   '-n', '$SERVER', '-i', '$SERVER_IP', '-s', 'tmp',
+                   '-u', '$USERNAME', '-p', '$PASSWORD', '-l', '$LOCAL_PATH/tarmode',
+                   '-d', '$PREFIX', '-b', smbclient3,
+                   '--subunit', '--', configuration, '-mSMB3'])
 
 plantestsuite("samba3.blackbox.net_usershare", "fileserver:local", [os.path.join(samba3srcdir, "script/tests/test_net_usershare.sh"), '$SERVER', '$SERVER_IP', '$USERNAME', '$PASSWORD', smbclient3])
 
diff --git a/source3/wscript b/source3/wscript
index e6d9936..633a365 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,20 @@ 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")
+    elif conf.CONFIG_GET('ENABLE_SELFTEST'):
+        raise Utils.WafError('libarchive library required for '
+                             '--enable-selftest')
+
 
     # check for DMAPI libs
     if Options.options.with_dmapi == False:
diff --git a/source4/dsdb/samdb/ldb_modules/wscript b/source4/dsdb/samdb/ldb_modules/wscript
index 91edbcb..bf07982 100644
--- a/source4/dsdb/samdb/ldb_modules/wscript
+++ b/source4/dsdb/samdb/ldb_modules/wscript
@@ -7,7 +7,7 @@ def set_options(opt):
     help += "This requires gpgme devel and python packages "
     help += "(e.g. libgpgme11-dev, python-gpgme on debian/ubuntu)."
 
-    opt.SAMBA3_ADD_OPTION('gpgme', default=None, help=(help))
+    opt.SAMBA3_ADD_OPTION('gpgme', default=True, help=(help))
 
     return
 
@@ -24,7 +24,8 @@ def configure(conf):
 
     conf.SET_TARGET_TYPE('gpgme', 'EMPTY')
 
-    if Options.options.with_gpgme != False:
+    if not Options.options.without_ad_dc \
+       and Options.options.with_gpgme != False:
         conf.find_program('gpgme-config', var='GPGME_CONFIG')
 
         if conf.env.GPGME_CONFIG:
@@ -36,7 +37,11 @@ def configure(conf):
             conf.DEFINE('ENABLE_GPGME', '1')
 
         if not conf.CONFIG_SET('ENABLE_GPGME'):
-            if Options.options.with_gpgme == True:
-                conf.fatal('GPGME support requested, but no suitable GPGME library found, eg libgpgme11-dev and python-gpgme')
-            else:
-                Logs.warn('no suitable GPGME library found')
+            conf.fatal("GPGME support not found. "
+                       "Try installing libgpgme11-dev or gpgme-devel "
+		       "and python-gpgme. "
+                       "Otherwise, use --without-gpgme to build without "
+                       "GPGME support or --without-ad-dc to build without "
+		       "the Samba AD DC. "
+                       "GPGME support is required for the GPG encrypted "
+                       "password sync feature")


-- 
Samba Shared Repository



More information about the samba-cvs mailing list