def configuration_signature(config):
    """
    Return a signature for a configuration (xml_generator_configuration_t)
    object.

    This can then be used as a key in the cache.
    This method must take into account anything about
    a configuration that could cause the declarations generated
    to be different between runs.

    """

    sig = hashlib.sha1()
    if isinstance(config, cxx_parsers_cfg.xml_generator_configuration_t):
        sig.update(str(config.xml_generator_path).encode())
    sig.update(str(config.working_directory).encode('utf-8'))
    if isinstance(config, cxx_parsers_cfg.xml_generator_configuration_t):
        sig.update(str(config.cflags).encode('utf-8'))
    for p in config.include_paths:
        sig.update(str(p).encode('utf-8'))
    for s in config.define_symbols:
        sig.update(str(s).encode('utf-8'))
    for u in config.undefine_symbols:
        sig.update(str(u).encode('utf-8'))
    return sig.hexdigest()
Return a signature for a configuration (xml_generator_configuration_t)
    object.

    This can then be used as a key in the cache.
    This method must take into account anything about
    a configuration that could cause the declarations generated
    to be different between runs.