From aced4017283e2614e80fb6f20fc85d3a284ad6c1 Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Thu, 10 May 2018 13:05:56 +1200 Subject: [PATCH] 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 Reviewed-by: Stefan Metzmacher Reviewed-by: Gary Lockyer --- source4/dsdb/samdb/ldb_modules/wscript | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/source4/dsdb/samdb/ldb_modules/wscript b/source4/dsdb/samdb/ldb_modules/wscript index 91edbcb2594d..bf0798204a47 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") -- 2.34.1