def compute_doxy_info(self):
        """
        Extract all the information required for
        the Documentation of TELEMAC preparing for Doxygen
        """
        cfg = self.configs[self.cfgname]
        # Get destination doxydocs: ...
        self.get_config_key('doxydocs', there=True, empty=True)
        # Get doxygen command: ...
        self.get_config_key('cmd_doxygen', there=True, empty=True)

        self.compute_modules_info()

        cfg['COMPILER'] = {}
        # Get modules: user list of module
        # in which 'system' means all existing modules,
        # and in which 'update' means an update only of the source files and
        # tags
        # and in which 'clean' means a rebuild of all source files and tags
        # and Get options: for the switches such as parallel, openmi, mumps,
        # etc.
        get, tbr = parse_user_modules(cfg, cfg['MODULES'])
        cfg['COMPILER'].update({'MODULES': get.split()})
        cfg['COMPILER'].update({'REBUILD': tbr})
        for mod in get.split():
            if mod not in cfg['MODULES']:
                raise TelemacException(\
                     '\nThe following module does not exist {}\n'.format(mod))
        for mod in get.split():
            if mod not in cfg['MODULES']:
                mod_idx = cfg['COMPILER']['MODULES'].index(mod)
                del cfg['COMPILER']['MODULES'][mod_idx]

        self.compute_zip_info()

        # Get system's suffixes for obj, lib, mod, and exe
        cfg['SYSTEM'] = {}
    def compute_vnv_info(self):
        """
        Extract all the information required for the validation
        of the relevant modules for each configuration
        The principal assumption is that the validation cases are
        either under:
          + val_root\\*
          + teldir\\examples\\module\\val_root\\*
        If the 'val_root' key is not in the config, the default
        path is assumed to be based on the second option
        """
        cfg = self.configs[self.cfgname]

        self.compute_modules_info()

        # Get libs_all: ... libs_artemis: ... mods_all: ... etc.
        # for every module in the list of modules to account for
        # specific external includes for all or each module
        for mod in cfg['MODULES']:
            cfg['MODULES'][mod].update(\
                {'mods': add_externals(cfg, 'mods', mod)\
                         .replace('<root>', cfg['root'])})
            cfg['MODULES'][mod].update(\
                {'incs': add_externals(cfg, 'incs', mod)\
                         .replace('<root>', cfg['root'])})
            cfg['MODULES'][mod].update(\
                {'libs': add_externals(cfg, 'libs', mod)\
                         .replace('<root>', cfg['root'])})

        cfg['VALIDATION'] = {}
        # Get validation: user list of module and there associated directories
        # in which 'system' means all existing modules,
        # and in which 'update' means a continuation,
        #     ignoring previously completed runs
        # and in which 'clean' means a re-run of all validation tests
        if 'val_root' not in cfg:
            val_root = path.realpath(path.join(cfg['root'], 'examples'))
            if not path.isdir(val_root):
                raise TelemacException(\
                 '\nNot able to find your validation set from the path: {} \n\n'
                 ' ... check the val_root key in your configuration file'
                 ''.format(val_root))
        else:
            val_root = cfg['val_root'].replace('<root>', cfg['root'])
        cfg['val_root'] = val_root

        _, examples, _ = next(walk(val_root))
        get, tbr = parse_user_modules(cfg, cfg['MODULES'])
        cfg['REBUILD'] = tbr
        # Removing specials module if we are not in system or if they are
        # not explicitly given
        specials = ['python3']
        # Removing python2 examples
        if 'python27' in examples:
            examples.remove('python27')

        for mod in specials:
            if not ("system" in cfg['modules'] or mod in cfg['modules']):
                examples.remove(mod)

        # Removing module that are not in the configuration
        for mod in list(examples):
            if mod not in get and mod in cfg['MODULES']:
                examples.remove(mod)
        # Exception for mascaret as it is not in cfg_telemac['MODULES']
        # Because it does not have a mascaret.dico file
        if 'mascaret' not in get:
            if 'mascaret' in examples:
                examples.remove('mascaret')
        for mod in examples:
            val_dir = path.join(val_root, mod)
            val_mod = get_files_validation_telemac(val_dir)
            if val_mod != {}:
                cfg['VALIDATION'].update(\
                     {mod: {'path': path.realpath(val_dir)}})
                cfg['VALIDATION'][mod].update(val_mod)

        self.compute_partel_info()

        self.compute_mpi_info()

        self.compute_hpc_info()

        self.compute_zip_info()

        self.compute_system_info()

        self.compute_trace_info()
    def compute_compilation_info(self, rescan=False, bypass=False):
        """
        Extract all the information required for
        the Compilation of TELEMAC
        Requires: root,
        Optional: mods_, incs_, libs_, ... and options

        @param cfgname (string) Name of the configuration
        @param rescan(boolean) check if it must rescan
        @param bypass(boolean) continue with a raise exception

        """
        cfg = self.configs[self.cfgname]

        tbd = self.compute_modules_info(rescan, bypass, add_odd=True)

        # ~~ Compilation options ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        #
        #  Get libs_all: ... libs_artemis: ... libs_passive: ...
        #  mods_all: ... etc.
        #  for every module in the list of modules to account for
        #  specific external includes for all or each module
        for mod in cfg['MODULES']:
            for ext in ['mods', 'incs', 'libs']:
                externals = add_externals(cfg, ext, mod)\
                            .replace('<root>', cfg['root'])
                cfg['MODULES'][mod][ext] = externals
        # Get cmd_obj: ... cmd_lib: ... cmd_exe: ...
        # the compiler dependent command lines to create obj, lib and exe
        for mod in cfg['MODULES']:
            for ext in ['obj', 'lib', 'exe', 'pyf', 'pyd']:
                externals = get_externals(cfg, ext, mod)\
                         .replace('<root>', cfg['root'])
                cfg['MODULES'][mod]['x' + ext] = externals

        cfg['COMPILER'] = {}
        #  Get modules: user list of module
        #  in which 'system' means all existing modules,
        #  and in which 'update' means a rebuild of the lib and exe
        #  and in which 'clean' means a rebuild of the obj, lib and exe
        #  and Get options: for the switches such as parallel, openmi, mumps,
        #  etc.
        get, tbr = parse_user_modules(cfg, cfg['MODULES'])
        get = get.split()
        #  Add extra modules for special effects as priority items (insert(0,))
        #  where can be passive, for instance
        for mod in cfg['ADDONES']:
            if mod not in get:
                get.insert(0, mod)
        #  Delayed removal of the relevant CMDF - exception made for mascaret
        for mod in tbd:
            if mod in get and mod != 'mascaret':
                for fle in tbd[mod]:
                    remove(fle)

        cfg['COMPILER']['MODULES'] = get
        cfg['COMPILER']['REBUILD'] = tbr
        for mod in get:
            if mod not in cfg['MODULES']:
                raise TelemacException(\
                        '\nThe following module does not exist '
                        '{} \n'.format(mod))

        self.compute_zip_info()

        self.compute_system_info()

        self.compute_trace_info()