[SCM] Samba Shared Repository - branch master updated

Kai Blin kai at samba.org
Mon May 6 12:12:02 MDT 2013


The branch, master has been updated
       via  9f36d0c build: default --with-regedit to "auto" instead of "yes"
       via  431eeef build: fix --with-regedit to properly honour the yes/no/auto scheme
       via  356b825 build: simplify ncurses checks: --with-regedit does not take a path list
      from  8d34f2f docs: update the description of the formulas in the idmap_autorid manpage

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


- Log -----------------------------------------------------------------
commit 9f36d0c447b2107798e560ce257026318952c5e2
Author: Michael Adam <obnox at samba.org>
Date:   Mon May 6 13:16:49 2013 +0200

    build: default --with-regedit to "auto" instead of "yes"
    
    This means we don't build regedit when there is no ncurses
    and this is not an error for the overall build.
    
    Signed-off-by: Michael Adam <obnox at samba.org>
    Reviewed-by: Kai Blin <kai at samba.org>
    
    Autobuild-User(master): Kai Blin <kai at samba.org>
    Autobuild-Date(master): Mon May  6 20:11:09 CEST 2013 on sn-devel-104

commit 431eeef9311a8e172dc782bc91492c94cc5fcde7
Author: Michael Adam <obnox at samba.org>
Date:   Mon May 6 14:14:02 2013 +0200

    build: fix --with-regedit to properly honour the yes/no/auto scheme
    
    I.e. fail configure when ncurses support is not found but
    regedit build was requested.
    
    Signed-off-by: Michael Adam <obnox at samba.org>
    Reviewed-by: Kai Blin <kai at samba.org>

commit 356b825838cd97cc43aaa4b108267d1bd5f16ca1
Author: Michael Adam <obnox at samba.org>
Date:   Mon May 6 13:19:24 2013 +0200

    build: simplify ncurses checks: --with-regedit does not take a path list
    
    --with-regedit is defined using SAMBA3_ADD_OPTION(), and can hence
    take the values "yes", "no", and "auto". So it is not possible to
    hand in paths to look for ncurses-config via this option.
    
    Signed-off-by: Michael Adam <obnox at samba.org>
    Reviewed-by: Kai Blin <kai at samba.org>

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

Summary of changes:
 source3/wscript                          |   19 +++++++++++++++++--
 source3/wscript_configure_system_ncurses |   18 ++++++++++--------
 2 files changed, 27 insertions(+), 10 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/wscript b/source3/wscript
index 28fa11f..5e45fac 100644
--- a/source3/wscript
+++ b/source3/wscript
@@ -47,7 +47,7 @@ def set_options(opt):
 
     opt.SAMBA3_ADD_OPTION('cluster-support', default=None)
 
-    opt.SAMBA3_ADD_OPTION('regedit', default=True)
+    opt.SAMBA3_ADD_OPTION('regedit', default=None)
 
     opt.add_option('--with-ctdb-dir',
                    help=("Directory under which ctdb is installed"),
@@ -1713,8 +1713,23 @@ main() {
     if conf.CHECK_HEADERS('cephfs/libcephfs.h', False, False, 'cephfs') and conf.CHECK_LIB('cephfs'):
         conf.DEFINE('HAVE_CEPH', '1')
 
-    if Options.options.with_regedit:
+    conf.env.build_regedit = False
+    if not Options.options.with_regedit == False:
         conf.PROCESS_SEPARATE_RULE('system_ncurses')
+        if conf.CONFIG_SET('HAVE_NCURSES'):
+            conf.env.build_regedit = True
+
+    if conf.env.build_regedit:
+        Logs.info("building regedit")
+    else:
+        if Options.options.with_regedit == False:
+            Logs.info("not building regedit (--without-regedit)")
+        elif Options.options.with_regedit == True:
+            Logs.error("ncurses not available, cannot build regedit")
+            conf.fatal("ncurses not available, but --with-regedit was specified")
+        else:
+            Logs.info("ncurses not available, not building regedit")
+
 
     default_static_modules.extend(TO_LIST('''pdb_smbpasswd pdb_tdbsam pdb_wbc_sam
                                       auth_sam auth_unix auth_winbind auth_wbc
diff --git a/source3/wscript_configure_system_ncurses b/source3/wscript_configure_system_ncurses
index e8c4ab5..5c80429 100644
--- a/source3/wscript_configure_system_ncurses
+++ b/source3/wscript_configure_system_ncurses
@@ -2,19 +2,13 @@ import Logs, Options, sys
 
 Logs.info("Looking for ncurses features")
 
-if isinstance(Options.options.with_regedit, list):
-    path_ncurses_config = [x+'/bin' for x in Options.options.with_regedit]
-else:
-    path_ncurses_config = None
-
-conf.find_program('ncurses5-config', path_list=path_ncurses_config, var='NCURSES_CONFIG')
+conf.find_program('ncurses5-config', var='NCURSES_CONFIG')
 if not conf.env.NCURSES_CONFIG:
-    conf.find_program('ncurses6-config', path_list=path_ncurses_config, var='NCURSES_CONFIG')
+    conf.find_program('ncurses6-config', var='NCURSES_CONFIG')
 
 if conf.env.NCURSES_CONFIG:
     conf.check_cfg(path=conf.env.NCURSES_CONFIG, args="--cflags --libs",
                package="", uselib_store="NCURSES")
-    conf.env.build_regedit = True
 
 conf.CHECK_HEADERS('ncurses.h menu.h panel.h form.h', lib='ncurses')
 
@@ -22,3 +16,11 @@ conf.CHECK_FUNCS_IN('initscr', 'ncurses')
 conf.CHECK_FUNCS_IN('set_menu_items item_count', 'menu')
 conf.CHECK_FUNCS_IN('new_panel show_panel', 'panel')
 conf.CHECK_FUNCS_IN('new_field new_form', 'form')
+
+if conf.CONFIG_SET('HAVE_NCURSES_H') and \
+   conf.CONFIG_SET('HAVE_MENU_H') and \
+   conf.CONFIG_SET('HAVE_PANEL_H') and \
+   conf.CONFIG_SET('HAVE_FORM_H'):
+    conf.DEFINE('HAVE_NCURSES', '1')
+else:
+    conf.undefine('HAVE_NCURSES')


-- 
Samba Shared Repository


More information about the samba-cvs mailing list