original_docstring: Modify an environment to work with a component builder.
  
    Args:
      env: Environment to clone.
      builder_name: Name of the builder.
      kwargs: Keyword arguments.
  
    Returns:
      A modified clone of the environment.
    
docstring: Modify an environment to work with a component builder.
docstring_tokens: Modify an environment to work with a component builder .
code: def _ComponentPlatformSetup(env, builder_name, **kwargs):
    """Modify an environment to work with a component builder.
  
    Args:
      env: Environment to clone.
      builder_name: Name of the builder.
      kwargs: Keyword arguments.
  
    Returns:
      A modified clone of the environment.
    """
    # Clone environment so we can modify it
    env = env.Clone()
  
    # Add all keyword arguments to the environment
    for k, v in kwargs.items():
      env[k] = v
  
    # Add compiler flags for included headers, if any
    env['INCLUDES'] = env.Flatten(env.subst_list(['$INCLUDES']))
    for h in env['INCLUDES']:
      env.Append(CCFLAGS=['${CCFLAG_INCLUDE}%s' % h])
  
    # Call platform-specific component setup function, if any
    if env.get('COMPONENT_PLATFORM_SETUP'):
      env['COMPONENT_PLATFORM_SETUP'](env, builder_name)
  
    # Return the modified environment
    return env
code_tokens: def _ComponentPlatformSetup ( env , builder_name , ** kwargs ) : env = env . Clone ( ) for k , v in kwargs . items ( ) : env [ k ] = v env [ 'INCLUDES' ] = env . Flatten ( env . subst_list ( [ '$INCLUDES' ] ) ) for h in env [ 'INCLUDES' ] : env . Append ( CCFLAGS = [ '${CCFLAG_INCLUDE}%s' % h ] ) if env . get ( 'COMPONENT_PLATFORM_SETUP' ) : env [ 'COMPONENT_PLATFORM_SETUP' ] ( env , builder_name ) return env
short_docstring: Modify an environment to work with a component builder.
short_docstring_tokens: Modify an environment to work with a component builder .
comment: """Modify an environment to work with a component builder.
  
    Args:
      env: Environment to clone.
      builder_name: Name of the builder.
      kwargs: Keyword arguments.
  
    Returns:
      A modified clone of the environment.
    """$SEP$# Clone environment so we can modify it$SEP$# Add all keyword arguments to the environment$SEP$# Add compiler flags for included headers, if any$SEP$# Call platform-specific component setup function, if any$SEP$# Return the modified environment