code: def generate(env,**kw):
    
    import SCons.Util
    from SCons.Tool.GettextCommon import _detect_msginit
    try:
      env['MSGINIT'] = _detect_msginit(env)
    except:
      env['MSGINIT'] = 'msginit'
    msginitcom = '$MSGINIT ${_MSGNoTranslator(__env__)} -l ${_MSGINITLOCALE}' \
               + ' $MSGINITFLAGS -i $SOURCE -o $TARGET'
    # NOTE: We set POTSUFFIX here, in case the 'xgettext' is not loaded
    #       (sometimes we really don't need it)
    env.SetDefault(
      POSUFFIX = ['.po'],
      POTSUFFIX = ['.pot'],
      _MSGINITLOCALE = '${TARGET.filebase}',
      _MSGNoTranslator = _optional_no_translator_flag,
      MSGINITCOM = msginitcom,
      MSGINITCOMSTR = '',
      MSGINITFLAGS = [ ],
      POAUTOINIT = False,
      POCREATE_ALIAS = 'po-create'
    )
    env.Append( BUILDERS = { '_POInitBuilder' : _POInitBuilder(env) } )
    env.AddMethod(_POInitBuilderWrapper, 'POInit')
    env.AlwaysBuild(env.Alias('$POCREATE_ALIAS'))
docs: Generate the `msginit` tool