class_docstr: Fill-in metadata and options that can be automatically derived
  (from other metadata/options, the file system or conventions)
class_docstr_tok: ["Fill-in","metadata","and","options","that","can","be","automatically","derived","(","from","other","metadata\/options",",","the","file","system","or","conventions",")"]
code: def _analyse_package_layout(self, ignore_ext_modules: bool) -> bool:
      if self._explicitly_specified(ignore_ext_modules):
          # For backward compatibility, just try to find modules/packages
          # when nothing is given
          return True
  
      log.debug(
          "No `packages` or `py_modules` configuration, performing "
          "automatic discovery."
      )
  
      return (
          self._analyse_explicit_layout()
          or self._analyse_src_layout()
          # flat-layout is the trickiest for discovery so it should be last
          or self._analyse_flat_layout()
      )
  
imports: import itertools
  import os
  from fnmatch import fnmatchcase
  from glob import glob
  from pathlib import Path
  from typing import TYPE_CHECKING, Dict, Iterable, Iterator, List, Mapping, Optional, Tuple, Union
  import _distutils_hack.override
  from distutils import log
  from distutils.util import convert_path
label_desc: Use image node_id 8 for calling the ConfigDiscovery obj's underlying member method code with example usage: obj._analyse_package_layout(ignore_ext_modules) and returns: unknown, True