(command.CommandList
  children: [
    (C {(export)} {(Lit_VarLike 'DESTTREE=') (/usr)})
    (C {(export)} {(Lit_VarLike 'INSDESTTREE=') (DQ )})
    (C {(export)} {(Lit_VarLike '_E_EXEDESTTREE_=') (DQ )})
    (C {(export)} {(Lit_VarLike '_E_DOCDESTTREE_=') (DQ )})
    (C {(export)} {(Lit_VarLike 'INSOPTIONS=') (DQ (-m0644))})
    (C {(export)} {(Lit_VarLike 'EXEOPTIONS=') (DQ (-m0755))})
    (C {(export)} {(Lit_VarLike 'LIBOPTIONS=') (DQ (-m0644))})
    (C {(export)} {(Lit_VarLike 'DIROPTIONS=') (DQ (-m0755))})
    (C {(export)} {(Lit_VarLike 'MOPREFIX=') (${ VSub_Name PN)})
    (C {(export)} {(Lit_VarLike 'PORTAGE_DOCOMPRESS_SIZE_LIMIT=') (DQ (128))})
    (C {(declare)} {(-a)} 
      {(Lit_VarLike 'PORTAGE_DOCOMPRESS=') 
        (sh_array_literal
          left: <Op_LParen '('>
          words: [
            (word.BracedTree
              parts: [(/usr/share/) (word_part.BracedTuple words:[{(doc)} {(info)} {(man)}])]
            )
          ]
        )
      }
    )
    (C {(declare)} {(-a)} 
      {(Lit_VarLike 'PORTAGE_DOCOMPRESS_SKIP=') 
        (sh_array_literal
          left: <Op_LParen '('>
          words: [{(/usr/share/doc/) (${ VSub_Name PF) (/html)}]
        )
      }
    )
    (command.ShFunction
      name: into
      body: 
        (command.BraceGroup
          children: [
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (C {(Lit_LBracket '[')} {(DQ ($ VSub_Number '$1'))} 
                          {(Lit_Equals '=') (Lit_Equals '=')} {(DQ (/))} {(Lit_RBracket ']')}
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [(C {(export)} {(Lit_VarLike 'DESTTREE=') (DQ )})]
                )
              ]
              else_action: [
                (C {(export)} {(Lit_VarLike 'DESTTREE=') ($ VSub_Number '$1')})
                (command.If
                  arms: [
                    (if_arm
                      cond: [
                        (command.Sentence
                          child: 
                            (command.Pipeline
                              children: [(C {(___eapi_has_prefix_variables)})]
                              negated: T
                            )
                          terminator: <Op_Semi ';'>
                        )
                      ]
                      action: [(C {(local)} {(Lit_VarLike 'ED=') (${ VSub_Name D)})]
                    )
                  ]
                )
                (command.If
                  arms: [
                    (if_arm
                      cond: [
                        (command.Sentence
                          child: 
                            (C {(Lit_LBracket '[')} {(KW_Bang '!')} {(-d)} 
                              {(DQ (${ VSub_Name ED) (${ VSub_Name DESTTREE))} {(Lit_RBracket ']')}
                            )
                          terminator: <Op_Semi ';'>
                        )
                      ]
                      action: [
                        (C {(install)} {(-d)} {(DQ (${ VSub_Name ED) (${ VSub_Name DESTTREE))})
                        (C {(local)} {(Lit_VarLike 'ret=') ($ VSub_QMark '$?')})
                        (command.If
                          arms: [
                            (if_arm
                              cond: [
                                (command.Sentence
                                  child: 
                                    (command.DBracket
                                      expr: 
                                        (bool_expr.Binary
                                          op_id: BoolBinary_ne
                                          left: {($ VSub_DollarName '$ret')}
                                          right: {(0)}
                                        )
                                    )
                                  terminator: <Op_Semi ';'>
                                )
                              ]
                              action: [
                                (C {(__helpers_die)} 
                                  {
                                    (DQ 
                                      (braced_var_sub
                                        token: <VSub_Name FUNCNAME>
                                        bracket_op: 
                                          (bracket_op.ArrayIndex
                                            expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                          )
                                      ) (' failed')
                                    )
                                  }
                                )
                                (command.ControlFlow
                                  token: <ControlFlow_Return return>
                                  arg_word: {($ VSub_DollarName '$ret')}
                                )
                              ]
                            )
                          ]
                        )
                      ]
                    )
                  ]
                )
              ]
            )
          ]
        )
    )
    (command.ShFunction
      name: insinto
      body: 
        (command.BraceGroup
          children: [
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (C {(Lit_LBracket '[')} {(DQ ($ VSub_Number '$1'))} 
                          {(Lit_Equals '=') (Lit_Equals '=')} {(DQ (/))} {(Lit_RBracket ']')}
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [(C {(export)} {(Lit_VarLike 'INSDESTTREE=') (DQ )})]
                )
              ]
              else_action: [
                (C {(export)} {(Lit_VarLike 'INSDESTTREE=') ($ VSub_Number '$1')})
                (command.If
                  arms: [
                    (if_arm
                      cond: [
                        (command.Sentence
                          child: 
                            (command.Pipeline
                              children: [(C {(___eapi_has_prefix_variables)})]
                              negated: T
                            )
                          terminator: <Op_Semi ';'>
                        )
                      ]
                      action: [(C {(local)} {(Lit_VarLike 'ED=') (${ VSub_Name D)})]
                    )
                  ]
                )
                (command.If
                  arms: [
                    (if_arm
                      cond: [
                        (command.Sentence
                          child: 
                            (C {(Lit_LBracket '[')} {(KW_Bang '!')} {(-d)} 
                              {(DQ (${ VSub_Name ED) (${ VSub_Name INSDESTTREE))} {(Lit_RBracket ']')}
                            )
                          terminator: <Op_Semi ';'>
                        )
                      ]
                      action: [
                        (C {(install)} {(-d)} {(DQ (${ VSub_Name ED) (${ VSub_Name INSDESTTREE))})
                        (C {(local)} {(Lit_VarLike 'ret=') ($ VSub_QMark '$?')})
                        (command.If
                          arms: [
                            (if_arm
                              cond: [
                                (command.Sentence
                                  child: 
                                    (command.DBracket
                                      expr: 
                                        (bool_expr.Binary
                                          op_id: BoolBinary_ne
                                          left: {($ VSub_DollarName '$ret')}
                                          right: {(0)}
                                        )
                                    )
                                  terminator: <Op_Semi ';'>
                                )
                              ]
                              action: [
                                (C {(__helpers_die)} 
                                  {
                                    (DQ 
                                      (braced_var_sub
                                        token: <VSub_Name FUNCNAME>
                                        bracket_op: 
                                          (bracket_op.ArrayIndex
                                            expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                          )
                                      ) (' failed')
                                    )
                                  }
                                )
                                (command.ControlFlow
                                  token: <ControlFlow_Return return>
                                  arg_word: {($ VSub_DollarName '$ret')}
                                )
                              ]
                            )
                          ]
                        )
                      ]
                    )
                  ]
                )
              ]
            )
          ]
        )
    )
    (command.ShFunction
      name: exeinto
      body: 
        (command.BraceGroup
          children: [
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (C {(Lit_LBracket '[')} {(DQ ($ VSub_Number '$1'))} 
                          {(Lit_Equals '=') (Lit_Equals '=')} {(DQ (/))} {(Lit_RBracket ']')}
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [(C {(export)} {(Lit_VarLike '_E_EXEDESTTREE_=') (DQ )})]
                )
              ]
              else_action: [
                (C {(export)} {(Lit_VarLike '_E_EXEDESTTREE_=') (DQ ($ VSub_Number '$1'))})
                (command.If
                  arms: [
                    (if_arm
                      cond: [
                        (command.Sentence
                          child: 
                            (command.Pipeline
                              children: [(C {(___eapi_has_prefix_variables)})]
                              negated: T
                            )
                          terminator: <Op_Semi ';'>
                        )
                      ]
                      action: [(C {(local)} {(Lit_VarLike 'ED=') (${ VSub_Name D)})]
                    )
                  ]
                )
                (command.If
                  arms: [
                    (if_arm
                      cond: [
                        (command.Sentence
                          child: 
                            (C {(Lit_LBracket '[')} {(KW_Bang '!')} {(-d)} 
                              {(DQ (${ VSub_Name ED) (${ VSub_Name _E_EXEDESTTREE_))} {(Lit_RBracket ']')}
                            )
                          terminator: <Op_Semi ';'>
                        )
                      ]
                      action: [
                        (C {(install)} {(-d)} {(DQ (${ VSub_Name ED) (${ VSub_Name _E_EXEDESTTREE_))})
                        (C {(local)} {(Lit_VarLike 'ret=') ($ VSub_QMark '$?')})
                        (command.If
                          arms: [
                            (if_arm
                              cond: [
                                (command.Sentence
                                  child: 
                                    (command.DBracket
                                      expr: 
                                        (bool_expr.Binary
                                          op_id: BoolBinary_ne
                                          left: {($ VSub_DollarName '$ret')}
                                          right: {(0)}
                                        )
                                    )
                                  terminator: <Op_Semi ';'>
                                )
                              ]
                              action: [
                                (C {(__helpers_die)} 
                                  {
                                    (DQ 
                                      (braced_var_sub
                                        token: <VSub_Name FUNCNAME>
                                        bracket_op: 
                                          (bracket_op.ArrayIndex
                                            expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                          )
                                      ) (' failed')
                                    )
                                  }
                                )
                                (command.ControlFlow
                                  token: <ControlFlow_Return return>
                                  arg_word: {($ VSub_DollarName '$ret')}
                                )
                              ]
                            )
                          ]
                        )
                      ]
                    )
                  ]
                )
              ]
            )
          ]
        )
    )
    (command.ShFunction
      name: docinto
      body: 
        (command.BraceGroup
          children: [
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (C {(Lit_LBracket '[')} {(DQ ($ VSub_Number '$1'))} 
                          {(Lit_Equals '=') (Lit_Equals '=')} {(DQ (/))} {(Lit_RBracket ']')}
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [(C {(export)} {(Lit_VarLike '_E_DOCDESTTREE_=') (DQ )})]
                )
              ]
              else_action: [
                (C {(export)} {(Lit_VarLike '_E_DOCDESTTREE_=') (DQ ($ VSub_Number '$1'))})
                (command.If
                  arms: [
                    (if_arm
                      cond: [
                        (command.Sentence
                          child: 
                            (command.Pipeline
                              children: [(C {(___eapi_has_prefix_variables)})]
                              negated: T
                            )
                          terminator: <Op_Semi ';'>
                        )
                      ]
                      action: [(C {(local)} {(Lit_VarLike 'ED=') (${ VSub_Name D)})]
                    )
                  ]
                )
                (command.If
                  arms: [
                    (if_arm
                      cond: [
                        (command.Sentence
                          child: 
                            (C {(Lit_LBracket '[')} {(KW_Bang '!')} {(-d)} 
                              {
                                (DQ (${ VSub_Name ED) (usr/share/doc/) (${ VSub_Name PF) (/) 
                                  (${ VSub_Name _E_DOCDESTTREE_)
                                )
                              } {(Lit_RBracket ']')}
                            )
                          terminator: <Op_Semi ';'>
                        )
                      ]
                      action: [
                        (C {(install)} {(-d)} 
                          {
                            (DQ (${ VSub_Name ED) (usr/share/doc/) (${ VSub_Name PF) (/) 
                              (${ VSub_Name _E_DOCDESTTREE_)
                            )
                          }
                        )
                        (C {(local)} {(Lit_VarLike 'ret=') ($ VSub_QMark '$?')})
                        (command.If
                          arms: [
                            (if_arm
                              cond: [
                                (command.Sentence
                                  child: 
                                    (command.DBracket
                                      expr: 
                                        (bool_expr.Binary
                                          op_id: BoolBinary_ne
                                          left: {($ VSub_DollarName '$ret')}
                                          right: {(0)}
                                        )
                                    )
                                  terminator: <Op_Semi ';'>
                                )
                              ]
                              action: [
                                (C {(__helpers_die)} 
                                  {
                                    (DQ 
                                      (braced_var_sub
                                        token: <VSub_Name FUNCNAME>
                                        bracket_op: 
                                          (bracket_op.ArrayIndex
                                            expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                          )
                                      ) (' failed')
                                    )
                                  }
                                )
                                (command.ControlFlow
                                  token: <ControlFlow_Return return>
                                  arg_word: {($ VSub_DollarName '$ret')}
                                )
                              ]
                            )
                          ]
                        )
                      ]
                    )
                  ]
                )
              ]
            )
          ]
        )
    )
    (command.ShFunction
      name: insopts
      body: 
        (command.BraceGroup
          children: [
            (C {(export)} {(Lit_VarLike 'INSOPTIONS=') (DQ ($ VSub_At '$@'))})
            (command.AndOr
              ops: [Op_DAmp]
              children: [
                (C {(has)} {(-s)} {(${ VSub_Name INSOPTIONS)})
                (C {(die)} {(DQ ('Never call insopts() with -s'))})
              ]
            )
          ]
        )
    )
    (command.ShFunction
      name: diropts
      body: 
        (command.BraceGroup
          children: [(C {(export)} {(Lit_VarLike 'DIROPTIONS=') (DQ ($ VSub_At '$@'))})]
        )
    )
    (command.ShFunction
      name: exeopts
      body: 
        (command.BraceGroup
          children: [
            (C {(export)} {(Lit_VarLike 'EXEOPTIONS=') (DQ ($ VSub_At '$@'))})
            (command.AndOr
              ops: [Op_DAmp]
              children: [
                (C {(has)} {(-s)} {(${ VSub_Name EXEOPTIONS)})
                (C {(die)} {(DQ ('Never call exeopts() with -s'))})
              ]
            )
          ]
        )
    )
    (command.ShFunction
      name: libopts
      body: 
        (command.BraceGroup
          children: [
            (C {(export)} {(Lit_VarLike 'LIBOPTIONS=') (DQ ($ VSub_At '$@'))})
            (command.AndOr
              ops: [Op_DAmp]
              children: [
                (C {(has)} {(-s)} {(${ VSub_Name LIBOPTIONS)})
                (C {(die)} {(DQ ('Never call libopts() with -s'))})
              ]
            )
          ]
        )
    )
    (command.ShFunction
      name: docompress
      body: 
        (command.BraceGroup
          children: [
            (command.AndOr
              ops: [Op_DPipe]
              children: [
                (C {(___eapi_has_docompress)})
                (C {(die)} {(DQ ("'docompress' not supported in this EAPI"))})
              ]
            )
            (C {(local)} {(f)} {(g)})
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.DBracket
                          expr: 
                            (bool_expr.Binary
                              op_id: BoolBinary_GlobEqual
                              left: {($ VSub_Number '$1')}
                              right: {(DQ (-x))}
                            )
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (C {(shift)})
                    (command.ForEach
                      iter_name: f
                      do_arg_iter: T
                      body: 
                        (command.DoGroup
                          children: [
                            (command.Sentence
                              child: 
                                (command.ShAssignment
                                  pairs: [
                                    (assign_pair
                                      lhs: (sh_lhs_expr.Name name:f)
                                      op: Equal
                                      rhs: 
                                        {
                                          (command_sub
                                            left_token: <Left_DollarParen '$('>
                                            command_list: 
                                              (command.CommandList
                                                children: [
                                                  (C {(__strip_duplicate_slashes)} 
                                                    {(DQ (${ VSub_Name f))}
                                                  )
                                                ]
                                              )
                                          )
                                        }
                                    )
                                  ]
                                )
                              terminator: <Op_Semi ';'>
                            )
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:f)
                                  op: Equal
                                  rhs: 
                                    {
                                      (braced_var_sub
                                        token: <VSub_Name f>
                                        suffix_op: 
                                          (suffix_op.Unary
                                            op_id: VOp1_Percent
                                            arg_word: {(Lit_Slash /)}
                                          )
                                      )
                                    }
                                )
                              ]
                            )
                            (command.AndOr
                              ops: [Op_DPipe]
                              children: [
                                (command.DBracket
                                  expr: 
                                    (bool_expr.Binary
                                      op_id: BoolBinary_GlobEqual
                                      left: 
                                        {
                                          (braced_var_sub
                                            token: <VSub_Name f>
                                            suffix_op: 
                                              (suffix_op.Slice
                                                begin: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                                length: (arith_expr.ArithWord w:{(Lit_Digits 1)})
                                              )
                                          )
                                        }
                                      right: {(/)}
                                    )
                                )
                                (command.ShAssignment
                                  pairs: [
                                    (assign_pair
                                      lhs: (sh_lhs_expr.Name name:f)
                                      op: Equal
                                      rhs: {(DQ (/) (${ VSub_Name f))}
                                    )
                                  ]
                                )
                              ]
                            )
                            (command.ForEach
                              iter_name: g
                              iter_words: [
                                {
                                  (DQ 
                                    (braced_var_sub
                                      token: <VSub_Name PORTAGE_DOCOMPRESS_SKIP>
                                      bracket_op: (bracket_op.WholeArray op_id:Lit_At)
                                    )
                                  )
                                }
                              ]
                              do_arg_iter: F
                              body: 
                                (command.DoGroup
                                  children: [
                                    (command.AndOr
                                      ops: [Op_DAmp]
                                      children: [
                                        (command.DBracket
                                          expr: 
                                            (bool_expr.Binary
                                              op_id: BoolBinary_GlobEqual
                                              left: {(${ VSub_Name f)}
                                              right: {(DQ (${ VSub_Name g))}
                                            )
                                        )
                                        (command.ControlFlow
                                          token: <ControlFlow_Continue continue>
                                          arg_word: {(2)}
                                        )
                                      ]
                                    )
                                  ]
                                )
                            )
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: 
                                    (sh_lhs_expr.IndexedName
                                      name: PORTAGE_DOCOMPRESS_SKIP
                                      index: 
                                        (arith_expr.ArithWord
                                          w: 
                                            {
                                              (braced_var_sub
                                                token: <VSub_Name PORTAGE_DOCOMPRESS_SKIP>
                                                prefix_op: VSub_Pound
                                                bracket_op: (bracket_op.WholeArray op_id:Lit_At)
                                              )
                                            }
                                        )
                                    )
                                  op: Equal
                                  rhs: {(${ VSub_Name f)}
                                )
                              ]
                            )
                          ]
                        )
                    )
                  ]
                )
              ]
              else_action: [
                (command.ForEach
                  iter_name: f
                  do_arg_iter: T
                  body: 
                    (command.DoGroup
                      children: [
                        (command.Sentence
                          child: 
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:f)
                                  op: Equal
                                  rhs: 
                                    {
                                      (command_sub
                                        left_token: <Left_DollarParen '$('>
                                        command_list: 
                                          (command.CommandList
                                            children: [
                                              (C {(__strip_duplicate_slashes)} {(DQ (${ VSub_Name f))})
                                            ]
                                          )
                                      )
                                    }
                                )
                              ]
                            )
                          terminator: <Op_Semi ';'>
                        )
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:f)
                              op: Equal
                              rhs: 
                                {
                                  (braced_var_sub
                                    token: <VSub_Name f>
                                    suffix_op: 
                                      (suffix_op.Unary
                                        op_id: VOp1_Percent
                                        arg_word: {(Lit_Slash /)}
                                      )
                                  )
                                }
                            )
                          ]
                        )
                        (command.AndOr
                          ops: [Op_DPipe]
                          children: [
                            (command.DBracket
                              expr: 
                                (bool_expr.Binary
                                  op_id: BoolBinary_GlobEqual
                                  left: 
                                    {
                                      (braced_var_sub
                                        token: <VSub_Name f>
                                        suffix_op: 
                                          (suffix_op.Slice
                                            begin: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                            length: (arith_expr.ArithWord w:{(Lit_Digits 1)})
                                          )
                                      )
                                    }
                                  right: {(/)}
                                )
                            )
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:f)
                                  op: Equal
                                  rhs: {(DQ (/) (${ VSub_Name f))}
                                )
                              ]
                            )
                          ]
                        )
                        (command.ForEach
                          iter_name: g
                          iter_words: [
                            {
                              (DQ 
                                (braced_var_sub
                                  token: <VSub_Name PORTAGE_DOCOMPRESS>
                                  bracket_op: (bracket_op.WholeArray op_id:Lit_At)
                                )
                              )
                            }
                          ]
                          do_arg_iter: F
                          body: 
                            (command.DoGroup
                              children: [
                                (command.AndOr
                                  ops: [Op_DAmp]
                                  children: [
                                    (command.DBracket
                                      expr: 
                                        (bool_expr.Binary
                                          op_id: BoolBinary_GlobEqual
                                          left: {(${ VSub_Name f)}
                                          right: {(DQ (${ VSub_Name g))}
                                        )
                                    )
                                    (command.ControlFlow
                                      token: <ControlFlow_Continue continue>
                                      arg_word: {(2)}
                                    )
                                  ]
                                )
                              ]
                            )
                        )
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: 
                                (sh_lhs_expr.IndexedName
                                  name: PORTAGE_DOCOMPRESS
                                  index: 
                                    (arith_expr.ArithWord
                                      w: 
                                        {
                                          (braced_var_sub
                                            token: <VSub_Name PORTAGE_DOCOMPRESS>
                                            prefix_op: VSub_Pound
                                            bracket_op: (bracket_op.WholeArray op_id:Lit_At)
                                          )
                                        }
                                    )
                                )
                              op: Equal
                              rhs: {(${ VSub_Name f)}
                            )
                          ]
                        )
                      ]
                    )
                )
              ]
            )
          ]
        )
    )
    (command.ShFunction
      name: useq
      body: 
        (command.BraceGroup
          children: [
            (command.AndOr
              ops: [Op_DPipe]
              children: [
                (C {(has)} {($ VSub_DollarName '$EBUILD_PHASE')} {(prerm)} {(postrm)})
                (C {(eqawarn)} 
                  {(DQ ("QA Notice: The 'useq' function is deprecated (replaced by 'use')"))}
                )
              ]
            )
            (C {(use)} {(${ VSub_Number 1)})
          ]
        )
    )
    (command.ShFunction
      name: usev
      body: 
        (command.BraceGroup
          children: [
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: (C {(use)} {(${ VSub_Number 1)})
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (C {(echo)} 
                      {
                        (DQ 
                          (braced_var_sub
                            token: <VSub_Number 1>
                            suffix_op: (suffix_op.Unary op_id:VOp1_Pound arg_word:{('!')})
                          )
                        )
                      }
                    )
                    (command.ControlFlow
                      token: <ControlFlow_Return return>
                      arg_word: {(0)}
                    )
                  ]
                )
              ]
            )
            (command.ControlFlow token:<ControlFlow_Return return> arg_word:{(1)})
          ]
        )
    )
    (command.If
      arms: [
        (if_arm
          cond: [(command.Sentence child:(C {(___eapi_has_usex)}) terminator:<Op_Semi ';'>)]
          action: [
            (command.ShFunction
              name: usex
              body: 
                (command.BraceGroup
                  children: [
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: (C {(use)} {(DQ ($ VSub_Number '$1'))})
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (C {(echo)} 
                              {
                                (DQ 
                                  (braced_var_sub
                                    token: <VSub_Number 2>
                                    suffix_op: (suffix_op.Unary op_id:VTest_Hyphen arg_word:{(yes)})
                                  ) ($ VSub_Number '$4')
                                )
                              }
                            )
                          ]
                        )
                      ]
                      else_action: [
                        (C {(echo)} 
                          {
                            (DQ 
                              (braced_var_sub
                                token: <VSub_Number 3>
                                suffix_op: (suffix_op.Unary op_id:VTest_Hyphen arg_word:{(no)})
                              ) ($ VSub_Number '$5')
                            )
                          }
                        )
                      ]
                    )
                    (command.ControlFlow
                      token: <ControlFlow_Return return>
                      arg_word: {(0)}
                    )
                  ]
                )
            )
          ]
        )
      ]
    )
    (command.ShFunction
      name: use
      body: 
        (command.BraceGroup
          children: [
            (C {(local)} {(Lit_VarLike 'u=') ($ VSub_Number '$1')})
            (C {(local)} {(Lit_VarLike 'found=') (0)})
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.DBracket
                          expr: 
                            (bool_expr.Binary
                              op_id: BoolBinary_GlobDEqual
                              left: 
                                {
                                  (braced_var_sub
                                    token: <VSub_Name u>
                                    suffix_op: 
                                      (suffix_op.Slice
                                        begin: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                        length: (arith_expr.ArithWord w:{(Lit_Digits 1)})
                                      )
                                  )
                                }
                              right: {(DQ ('!'))}
                            )
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:u)
                          op: Equal
                          rhs: 
                            {
                              (braced_var_sub
                                token: <VSub_Name u>
                                suffix_op: 
                                  (suffix_op.Slice
                                    begin: (arith_expr.ArithWord w:{(Lit_Digits 1)})
                                  )
                              )
                            }
                        )
                      ]
                    )
                    (command.ShAssignment
                      pairs: [(assign_pair lhs:(sh_lhs_expr.Name name:found) op:Equal rhs:{(1)})]
                    )
                  ]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.DBracket
                          expr: 
                            (bool_expr.Binary
                              op_id: BoolBinary_GlobEqual
                              left: {($ VSub_DollarName '$EBUILD_PHASE')}
                              right: {(depend)}
                            )
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [(C {(true)})]
                )
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.DBracket
                          expr: 
                            (bool_expr.LogicalAnd
                              left: 
                                (bool_expr.Unary
                                  op_id: BoolUnary_n
                                  child: {($ VSub_DollarName '$PORTAGE_IUSE')}
                                )
                              right: 
                                (bool_expr.LogicalAnd
                                  left: 
                                    (bool_expr.Unary
                                      op_id: BoolUnary_n
                                      child: {($ VSub_DollarName '$EBUILD_PHASE')}
                                    )
                                  right: 
                                    (bool_expr.Unary
                                      op_id: BoolUnary_n
                                      child: {($ VSub_DollarName '$PORTAGE_INTERNAL_CALLER')}
                                    )
                                )
                            )
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.DBracket
                                  expr: 
                                    (bool_expr.LogicalNot
                                      child: 
                                        (bool_expr.Binary
                                          op_id: BoolBinary_EqualTilde
                                          left: {($ VSub_DollarName '$u')}
                                          right: {($ VSub_DollarName '$PORTAGE_IUSE')}
                                        )
                                    )
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.DBracket
                                          expr: 
                                            (bool_expr.LogicalNot
                                              child: 
                                                (bool_expr.Binary
                                                  op_id: BoolBinary_EqualTilde
                                                  left: {(${ VSub_Name EAPI)}
                                                  right: 
                                                    {(Lit_Other '^') (Lit_Other '(') (0) 
                                                      (Lit_Other '|') (1) (Lit_Other '|') (2) (Lit_Other '|') (3) (Lit_Other '|') (4) (Lit_Other '|') (4-python) (Lit_Other '|') 
                                                      (4-slot-abi) (Lit_Other ')') (Lit_Other '$')
                                                    }
                                                )
                                            )
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(die)} 
                                      {
                                        (DQ ("USE Flag '") (${ VSub_Name u) ("' not in IUSE for ") 
                                          (${ VSub_Name CATEGORY) (/) (${ VSub_Name PF)
                                        )
                                      }
                                    )
                                  ]
                                )
                              ]
                            )
                            (C {(eqawarn)} {(DQ ("QA Notice: USE Flag '") (${ VSub_Name u) ("' not"))} 
                              {(DQ ('in IUSE for ') (${ VSub_Name CATEGORY) (/) (${ VSub_Name PF))}
                            )
                          ]
                        )
                      ]
                    )
                  ]
                )
              ]
            )
            (C {(local)} 
              {(Lit_VarLike 'IFS=') 
                (single_quoted
                  left: <Left_SingleQuoteC "$'">
                  tokens: [<Char_Literals ' '> <Char_OneChar '\\t'> <Char_OneChar '\\n'>]
                )
              } {(Lit_VarLike 'prev_shopts=') ($ VSub_Hyphen '$-')} {(ret)}
            )
            (C {(KW_Set set)} {(-f)})
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: (C {(has)} {(${ VSub_Name u)} {(${ VSub_Name USE)})
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:ret)
                          op: Equal
                          rhs: {(${ VSub_Name found)}
                        )
                      ]
                    )
                  ]
                )
              ]
              else_action: [
                (command.ShAssignment
                  pairs: [
                    (assign_pair
                      lhs: (sh_lhs_expr.Name name:ret)
                      op: Equal
                      rhs: 
                        {
                          (word_part.ArithSub
                            anode: 
                              (arith_expr.Unary
                                op_id: Arith_Bang
                                child: (arith_expr.VarRef token:<Lit_ArithVarLike found>)
                              )
                          )
                        }
                    )
                  ]
                )
              ]
            )
            (command.AndOr
              ops: [Op_DPipe]
              children: [
                (command.DBracket
                  expr: 
                    (bool_expr.Binary
                      op_id: BoolBinary_GlobDEqual
                      left: {(${ VSub_Name prev_shopts)}
                      right: {(Lit_Other '*') (f) (Lit_Other '*')}
                    )
                )
                (C {(KW_Set set)} {(Lit_Other '+') (f)})
              ]
            )
            (command.ControlFlow
              token: <ControlFlow_Return return>
              arg_word: {(${ VSub_Name ret)}
            )
          ]
        )
    )
    (command.ShFunction
      name: use_with
      body: 
        (command.BraceGroup
          children: [
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (C {(Lit_LBracket '[')} {(-z)} {(DQ ($ VSub_Number '$1'))} {(Lit_RBracket ']')})
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (command.Simple
                      words: [{(echo)} {(DQ ('!!! use_with() called without a parameter.'))}]
                      redirects: [(redir.Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(2)})]
                    )
                    (command.Simple
                      words: [{(echo)} {(DQ ('!!! use_with <USEFLAG> [<flagname> [value]]'))}]
                      redirects: [(redir.Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(2)})]
                    )
                    (command.ControlFlow
                      token: <ControlFlow_Return return>
                      arg_word: {(1)}
                    )
                  ]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: (C {(___eapi_use_enable_and_use_with_support_empty_third_argument)})
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (C {(local)} 
                      {(Lit_VarLike 'UW_SUFFIX=') 
                        (braced_var_sub
                          token: <VSub_Number 3>
                          suffix_op: 
                            (suffix_op.Unary
                              op_id: VTest_Plus
                              arg_word: {('=') ($ VSub_Number '$3')}
                            )
                        )
                      }
                    )
                  ]
                )
              ]
              else_action: [
                (C {(local)} 
                  {(Lit_VarLike 'UW_SUFFIX=') 
                    (braced_var_sub
                      token: <VSub_Number 3>
                      suffix_op: 
                        (suffix_op.Unary
                          op_id: VTest_ColonPlus
                          arg_word: {('=') ($ VSub_Number '$3')}
                        )
                    )
                  }
                )
              ]
            )
            (C {(local)} 
              {(Lit_VarLike 'UWORD=') 
                (braced_var_sub
                  token: <VSub_Number 2>
                  suffix_op: (suffix_op.Unary op_id:VTest_ColonHyphen arg_word:{($ VSub_Number '$1')})
                )
              }
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: (C {(use)} {($ VSub_Number '$1')})
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [(C {(echo)} {(DQ (--with-) (${ VSub_Name UWORD) (${ VSub_Name UW_SUFFIX))})]
                )
              ]
              else_action: [(C {(echo)} {(DQ (--without-) (${ VSub_Name UWORD))})]
            )
            (command.ControlFlow token:<ControlFlow_Return return> arg_word:{(0)})
          ]
        )
    )
    (command.ShFunction
      name: use_enable
      body: 
        (command.BraceGroup
          children: [
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (C {(Lit_LBracket '[')} {(-z)} {(DQ ($ VSub_Number '$1'))} {(Lit_RBracket ']')})
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (command.Simple
                      words: [{(echo)} {(DQ ('!!! use_enable() called without a parameter.'))}]
                      redirects: [(redir.Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(2)})]
                    )
                    (command.Simple
                      words: [{(echo)} {(DQ ('!!! use_enable <USEFLAG> [<flagname> [value]]'))}]
                      redirects: [(redir.Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(2)})]
                    )
                    (command.ControlFlow
                      token: <ControlFlow_Return return>
                      arg_word: {(1)}
                    )
                  ]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: (C {(___eapi_use_enable_and_use_with_support_empty_third_argument)})
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (C {(local)} 
                      {(Lit_VarLike 'UE_SUFFIX=') 
                        (braced_var_sub
                          token: <VSub_Number 3>
                          suffix_op: 
                            (suffix_op.Unary
                              op_id: VTest_Plus
                              arg_word: {('=') ($ VSub_Number '$3')}
                            )
                        )
                      }
                    )
                  ]
                )
              ]
              else_action: [
                (C {(local)} 
                  {(Lit_VarLike 'UE_SUFFIX=') 
                    (braced_var_sub
                      token: <VSub_Number 3>
                      suffix_op: 
                        (suffix_op.Unary
                          op_id: VTest_ColonPlus
                          arg_word: {('=') ($ VSub_Number '$3')}
                        )
                    )
                  }
                )
              ]
            )
            (C {(local)} 
              {(Lit_VarLike 'UWORD=') 
                (braced_var_sub
                  token: <VSub_Number 2>
                  suffix_op: (suffix_op.Unary op_id:VTest_ColonHyphen arg_word:{($ VSub_Number '$1')})
                )
              }
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: (C {(use)} {($ VSub_Number '$1')})
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [(C {(echo)} {(DQ (--enable-) (${ VSub_Name UWORD) (${ VSub_Name UE_SUFFIX))})]
                )
              ]
              else_action: [(C {(echo)} {(DQ (--disable-) (${ VSub_Name UWORD))})]
            )
            (command.ControlFlow token:<ControlFlow_Return return> arg_word:{(0)})
          ]
        )
    )
    (command.ShFunction
      name: unpack
      body: 
        (command.BraceGroup
          children: [
            (C {(local)} {(srcdir)})
            (C {(local)} {(x)})
            (C {(local)} {(y)} {(y_insensitive)})
            (C {(local)} {(suffix)} {(suffix_insensitive)})
            (C {(local)} {(myfail)})
            (C {(local)} 
              {(Lit_VarLike 'eapi=') 
                (braced_var_sub
                  token: <VSub_Name EAPI>
                  suffix_op: (suffix_op.Unary op_id:VTest_ColonHyphen arg_word:{(0)})
                )
              }
            )
            (command.AndOr
              ops: [Op_DAmp]
              children: [
                (C {(Lit_LBracket '[')} {(-z)} {(DQ ($ VSub_Star '$*'))} {(Lit_RBracket ']')})
                (C {(die)} {(DQ ("Nothing passed to the 'unpack' command"))})
              ]
            )
            (command.ForEach
              iter_name: x
              iter_words: [{(DQ ($ VSub_At '$@'))}]
              do_arg_iter: F
              body: 
                (command.DoGroup
                  children: [
                    (C {(__vecho)} 
                      {(DQ ('>>> Unpacking ') (${ VSub_Name x) (' to ') (${ VSub_Name PWD))}
                    )
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:suffix)
                          op: Equal
                          rhs: 
                            {
                              (braced_var_sub
                                token: <VSub_Name x>
                                suffix_op: (suffix_op.Unary op_id:VOp1_DPound arg_word:{('*.')})
                              )
                            }
                        )
                      ]
                    )
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:suffix_insensitive)
                          op: Equal
                          rhs: 
                            {
                              (command_sub
                                left_token: <Left_DollarParen '$('>
                                command_list: 
                                  (command.CommandList
                                    children: [
                                      (command.Simple
                                        words: [{(tr)} {(DQ ('[:upper:]'))} {(DQ ('[:lower:]'))}]
                                        redirects: [
                                          (redir.Redir
                                            op: <Redir_TLess '<<<'>
                                            fd: 16777215
                                            arg_word: {(DQ (${ VSub_Name suffix))}
                                          )
                                        ]
                                        more_env: [(env_pair name:LC_ALL val:{(C)})]
                                      )
                                    ]
                                  )
                              )
                            }
                        )
                      ]
                    )
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:y)
                          op: Equal
                          rhs: 
                            {
                              (braced_var_sub
                                token: <VSub_Name x>
                                suffix_op: (suffix_op.Unary op_id:VOp1_Percent arg_word:{('.*')})
                              )
                            }
                        )
                      ]
                    )
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:y)
                          op: Equal
                          rhs: 
                            {
                              (braced_var_sub
                                token: <VSub_Name y>
                                suffix_op: (suffix_op.Unary op_id:VOp1_DPound arg_word:{('*.')})
                              )
                            }
                        )
                      ]
                    )
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:y_insensitive)
                          op: Equal
                          rhs: 
                            {
                              (command_sub
                                left_token: <Left_DollarParen '$('>
                                command_list: 
                                  (command.CommandList
                                    children: [
                                      (command.Simple
                                        words: [{(tr)} {(DQ ('[:upper:]'))} {(DQ ('[:lower:]'))}]
                                        redirects: [
                                          (redir.Redir
                                            op: <Redir_TLess '<<<'>
                                            fd: 16777215
                                            arg_word: {(DQ (${ VSub_Name y))}
                                          )
                                        ]
                                        more_env: [(env_pair name:LC_ALL val:{(C)})]
                                      )
                                    ]
                                  )
                              )
                            }
                        )
                      ]
                    )
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.DBracket
                                  expr: 
                                    (bool_expr.Binary
                                      op_id: BoolBinary_GlobNEqual
                                      left: {(${ VSub_Name x)}
                                      right: {(Lit_Other '*') (/) (Lit_Other '*')}
                                    )
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:srcdir)
                                  op: Equal
                                  rhs: {(${ VSub_Name DISTDIR) (/)}
                                )
                              ]
                            )
                          ]
                        )
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.DBracket
                                  expr: 
                                    (bool_expr.Binary
                                      op_id: BoolBinary_GlobDEqual
                                      left: {(${ VSub_Name x)}
                                      right: {(./) (Lit_Other '*')}
                                    )
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (command.ShAssignment
                              pairs: [(assign_pair lhs:(sh_lhs_expr.Name name:srcdir) op:Equal rhs:(word.Empty))]
                            )
                          ]
                        )
                      ]
                      else_action: [
                        (command.If
                          arms: [
                            (if_arm
                              cond: [
                                (command.Sentence
                                  child: (C {(___eapi_unpack_supports_absolute_paths)})
                                  terminator: <Op_Semi ';'>
                                )
                              ]
                              action: [
                                (command.ShAssignment
                                  pairs: [(assign_pair lhs:(sh_lhs_expr.Name name:srcdir) op:Equal rhs:(word.Empty))]
                                )
                                (command.If
                                  arms: [
                                    (if_arm
                                      cond: [
                                        (command.Sentence
                                          child: 
                                            (command.DBracket
                                              expr: 
                                                (bool_expr.Binary
                                                  op_id: BoolBinary_GlobDEqual
                                                  left: {(${ VSub_Name x)}
                                                  right: 
                                                    {
                                                      (braced_var_sub
                                                        token: <VSub_Name DISTDIR>
                                                        suffix_op: 
                                                          (suffix_op.Unary
                                                            op_id: VOp1_Percent
                                                            arg_word: {(Lit_Slash /)}
                                                          )
                                                      ) (/) (Lit_Other '*')
                                                    }
                                                )
                                            )
                                          terminator: <Op_Semi ';'>
                                        )
                                      ]
                                      action: [
                                        (C {(eqawarn)} 
                                          {
                                            (DQ ('QA Notice: unpack called with redundant ') 
                                              (word_part.EscapedLiteral
                                                token: <Lit_EscapedChar '\\$'>
                                              ) ('{DISTDIR} in path')
                                            )
                                          }
                                        )
                                      ]
                                    )
                                  ]
                                )
                              ]
                            )
                            (if_arm
                              cond: [
                                (command.Sentence
                                  child: 
                                    (command.DBracket
                                      expr: 
                                        (bool_expr.Binary
                                          op_id: BoolBinary_GlobDEqual
                                          left: {(${ VSub_Name x)}
                                          right: 
                                            {
                                              (braced_var_sub
                                                token: <VSub_Name DISTDIR>
                                                suffix_op: 
                                                  (suffix_op.Unary
                                                    op_id: VOp1_Percent
                                                    arg_word: {(Lit_Slash /)}
                                                  )
                                              ) (/) (Lit_Other '*')
                                            }
                                        )
                                    )
                                  terminator: <Op_Semi ';'>
                                )
                              ]
                              action: [
                                (C {(die)} 
                                  {
                                    (DQ ('Arguments to unpack() cannot begin with ') 
                                      (word_part.EscapedLiteral
                                        token: <Lit_EscapedChar '\\$'>
                                      ) ('{DISTDIR} in EAPI ') (${ VSub_Name EAPI)
                                    )
                                  }
                                )
                              ]
                            )
                            (if_arm
                              cond: [
                                (command.Sentence
                                  child: 
                                    (command.DBracket
                                      expr: 
                                        (bool_expr.Binary
                                          op_id: BoolBinary_GlobDEqual
                                          left: {(${ VSub_Name x)}
                                          right: {(/) (Lit_Other '*')}
                                        )
                                    )
                                  terminator: <Op_Semi ';'>
                                )
                              ]
                              action: [
                                (C {(die)} 
                                  {
                                    (DQ ('Arguments to unpack() cannot be absolute in EAPI ') 
                                      (${ VSub_Name EAPI)
                                    )
                                  }
                                )
                              ]
                            )
                          ]
                          else_action: [
                            (C {(die)} 
                              {
                                (DQ 
                                  ("Relative paths to unpack() must be prefixed with './' in EAPI ") (${ VSub_Name EAPI)
                                )
                              }
                            )
                          ]
                        )
                      ]
                    )
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.DBracket
                                  expr: 
                                    (bool_expr.LogicalNot
                                      child: 
                                        (bool_expr.Unary
                                          op_id: BoolUnary_s
                                          child: {(${ VSub_Name srcdir) (${ VSub_Name x)}
                                        )
                                    )
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (C {(__helpers_die)} 
                              {(DQ ('unpack: ') (${ VSub_Name x) (' does not exist'))}
                            )
                            (command.ControlFlow
                              token: <ControlFlow_Return return>
                              arg_word: {(1)}
                            )
                          ]
                        )
                      ]
                    )
                    (command.ShFunction
                      name: __unpack_tar
                      body: 
                        (command.BraceGroup
                          children: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.DBracket
                                          expr: 
                                            (bool_expr.Binary
                                              op_id: BoolBinary_GlobDEqual
                                              left: {(${ VSub_Name y_insensitive)}
                                              right: {(tar)}
                                            )
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (command.If
                                      arms: [
                                        (if_arm
                                          cond: [
                                            (command.Sentence
                                              child: 
                                                (command.AndOr
                                                  ops: [Op_DAmp]
                                                  children: [
                                                    (C {(___eapi_unpack_is_case_sensitive)})
                                                    (command.DBracket
                                                      expr: 
                                                        (bool_expr.Binary
                                                          op_id: BoolBinary_GlobNEqual
                                                          left: {(tar)}
                                                          right: {(${ VSub_Name y)}
                                                        )
                                                    )
                                                  ]
                                                )
                                              terminator: <Op_Semi ';'>
                                            )
                                          ]
                                          action: [
                                            (C {(eqawarn)} {(DQ ('QA Notice: unpack called with'))} 
                                              {
                                                (DQ ("secondary suffix '") (${ VSub_Name y) 
                                                  ("' which is unofficially")
                                                )
                                              } {(DQ ("supported with EAPI '") (${ VSub_Name EAPI) ("'. Instead use 'tar'."))}
                                            )
                                          ]
                                        )
                                      ]
                                    )
                                    (command.Pipeline
                                      children: [
                                        (C {($ VSub_Number '$1')} {(-c)} {(--)} 
                                          {
                                            (DQ ($ VSub_DollarName '$srcdir') ($ VSub_DollarName '$x'))
                                          }
                                        )
                                        (C {(tar)} {(xof)} {(-)})
                                      ]
                                      negated: F
                                    )
                                    (command.AndOr
                                      ops: [Op_DPipe]
                                      children: [
                                        (C {(__assert_sigpipe_ok)} {(DQ ($ VSub_DollarName '$myfail'))})
                                        (command.ControlFlow
                                          token: <ControlFlow_Return return>
                                          arg_word: {(1)}
                                        )
                                      ]
                                    )
                                  ]
                                )
                              ]
                              else_action: [
                                (C {(local)} 
                                  {(Lit_VarLike 'cwd_dest=') 
                                    (braced_var_sub
                                      token: <VSub_Name x>
                                      suffix_op: 
                                        (suffix_op.Unary
                                          op_id: VOp1_DPound
                                          arg_word: {('*') (Lit_Slash /)}
                                        )
                                    )
                                  }
                                )
                                (command.ShAssignment
                                  pairs: [
                                    (assign_pair
                                      lhs: (sh_lhs_expr.Name name:cwd_dest)
                                      op: Equal
                                      rhs: 
                                        {
                                          (braced_var_sub
                                            token: <VSub_Name cwd_dest>
                                            suffix_op: 
                                              (suffix_op.Unary
                                                op_id: VOp1_Percent
                                                arg_word: {('.*')}
                                              )
                                          )
                                        }
                                    )
                                  ]
                                )
                                (command.If
                                  arms: [
                                    (if_arm
                                      cond: [
                                        (command.Sentence
                                          child: 
                                            (command.Pipeline
                                              children: [
                                                (command.Simple
                                                  words: [
                                                    {($ VSub_Number '$1')}
                                                    {(-c)}
                                                    {(--)}
                                                    {(DQ (${ VSub_Name srcdir) (${ VSub_Name x))}
                                                  ]
                                                  redirects: [
                                                    (redir.Redir
                                                      op: <Redir_Great '>'>
                                                      fd: 16777215
                                                      arg_word: {(DQ (${ VSub_Name cwd_dest))}
                                                    )
                                                  ]
                                                )
                                              ]
                                              negated: T
                                            )
                                          terminator: <Op_Semi ';'>
                                        )
                                      ]
                                      action: [
                                        (C {(__helpers_die)} {(DQ ($ VSub_DollarName '$myfail'))})
                                        (command.ControlFlow
                                          token: <ControlFlow_Return return>
                                          arg_word: {(1)}
                                        )
                                      ]
                                    )
                                  ]
                                )
                              ]
                            )
                          ]
                        )
                    )
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:myfail)
                          op: Equal
                          rhs: {(DQ ('unpack: failure unpacking ') (${ VSub_Name x))}
                        )
                      ]
                    )
                    (command.Case
                      to_match: {(DQ (${ VSub_Name suffix_insensitive))}
                      arms: [
                        (case_arm
                          pat_list: [{(tar)}]
                          action: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.AndOr
                                          ops: [Op_DAmp]
                                          children: [
                                            (C {(___eapi_unpack_is_case_sensitive)})
                                            (command.DBracket
                                              expr: 
                                                (bool_expr.Binary
                                                  op_id: BoolBinary_GlobNEqual
                                                  left: {(tar)}
                                                  right: {(${ VSub_Name suffix)}
                                                )
                                            )
                                          ]
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(eqawarn)} {(DQ ('QA Notice: unpack called with'))} 
                                      {
                                        (DQ ("suffix '") (${ VSub_Name suffix) 
                                          ("' which is unofficially supported")
                                        )
                                      } {(DQ ("with EAPI '") (${ VSub_Name EAPI) ("'. Instead use 'tar'."))}
                                    )
                                  ]
                                )
                              ]
                            )
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.Pipeline
                                          children: [
                                            (C {(tar)} {(xof)} 
                                              {
                                                (DQ ($ VSub_DollarName '$srcdir') 
                                                  ($ VSub_DollarName '$x')
                                                )
                                              }
                                            )
                                          ]
                                          negated: T
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(__helpers_die)} {(DQ ($ VSub_DollarName '$myfail'))})
                                    (command.ControlFlow
                                      token: <ControlFlow_Return return>
                                      arg_word: {(1)}
                                    )
                                  ]
                                )
                              ]
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(tgz)}]
                          action: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.AndOr
                                          ops: [Op_DAmp]
                                          children: [
                                            (C {(___eapi_unpack_is_case_sensitive)})
                                            (command.DBracket
                                              expr: 
                                                (bool_expr.Binary
                                                  op_id: BoolBinary_GlobNEqual
                                                  left: {(tgz)}
                                                  right: {(${ VSub_Name suffix)}
                                                )
                                            )
                                          ]
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(eqawarn)} {(DQ ('QA Notice: unpack called with'))} 
                                      {
                                        (DQ ("suffix '") (${ VSub_Name suffix) 
                                          ("' which is unofficially supported")
                                        )
                                      } {(DQ ("with EAPI '") (${ VSub_Name EAPI) ("'. Instead use 'tgz'."))}
                                    )
                                  ]
                                )
                              ]
                            )
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.Pipeline
                                          children: [
                                            (C {(tar)} {(xozf)} 
                                              {
                                                (DQ ($ VSub_DollarName '$srcdir') 
                                                  ($ VSub_DollarName '$x')
                                                )
                                              }
                                            )
                                          ]
                                          negated: T
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(__helpers_die)} {(DQ ($ VSub_DollarName '$myfail'))})
                                    (command.ControlFlow
                                      token: <ControlFlow_Return return>
                                      arg_word: {(1)}
                                    )
                                  ]
                                )
                              ]
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(tbz)} {(tbz2)}]
                          action: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.AndOr
                                          ops: [Op_DAmp]
                                          children: [
                                            (C {(___eapi_unpack_is_case_sensitive)})
                                            (command.DBracket
                                              expr: 
                                                (bool_expr.Binary
                                                  op_id: BoolBinary_GlobNEqual
                                                  left: {(DQ (' tbz tbz2 '))}
                                                  right: 
                                                    {(Lit_Other '*') 
                                                      (DQ (' ') (${ VSub_Name suffix) (' ')) (Lit_Other '*')
                                                    }
                                                )
                                            )
                                          ]
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(eqawarn)} {(DQ ('QA Notice: unpack called with'))} 
                                      {
                                        (DQ ("suffix '") (${ VSub_Name suffix) 
                                          ("' which is unofficially supported")
                                        )
                                      } {(DQ ("with EAPI '") (${ VSub_Name EAPI) ("'. Instead use 'tbz' or 'tbz2'."))}
                                    )
                                  ]
                                )
                              ]
                            )
                            (command.Pipeline
                              children: [
                                (C 
                                  {
                                    (braced_var_sub
                                      token: <VSub_Name PORTAGE_BUNZIP2_COMMAND>
                                      suffix_op: 
                                        (suffix_op.Unary
                                          op_id: VTest_ColonHyphen
                                          arg_word: {(${ VSub_Name PORTAGE_BZIP2_COMMAND) (' -d')}
                                        )
                                    )
                                  } {(-c)} {(--)} {(DQ ($ VSub_DollarName '$srcdir') ($ VSub_DollarName '$x'))}
                                )
                                (C {(tar)} {(xof)} {(-)})
                              ]
                              negated: F
                            )
                            (command.AndOr
                              ops: [Op_DPipe]
                              children: [
                                (C {(__assert_sigpipe_ok)} {(DQ ($ VSub_DollarName '$myfail'))})
                                (command.ControlFlow
                                  token: <ControlFlow_Return return>
                                  arg_word: {(1)}
                                )
                              ]
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(zip)} {(jar)}]
                          action: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.AndOr
                                          ops: [Op_DAmp]
                                          children: [
                                            (C {(___eapi_unpack_is_case_sensitive)})
                                            (command.DBracket
                                              expr: 
                                                (bool_expr.Binary
                                                  op_id: BoolBinary_GlobNEqual
                                                  left: {(DQ (' ZIP zip jar '))}
                                                  right: 
                                                    {(Lit_Other '*') 
                                                      (DQ (' ') (${ VSub_Name suffix) (' ')) (Lit_Other '*')
                                                    }
                                                )
                                            )
                                          ]
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(eqawarn)} {(DQ ('QA Notice: unpack called with'))} 
                                      {
                                        (DQ ("suffix '") (${ VSub_Name suffix) 
                                          ("' which is unofficially supported")
                                        )
                                      } {(DQ ("with EAPI '") (${ VSub_Name EAPI) ("'."))} {(DQ ("Instead use 'ZIP', 'zip', or 'jar'."))}
                                    )
                                  ]
                                )
                              ]
                            )
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.Pipeline
                                          children: [
                                            (C {(unzip)} {(-qo)} 
                                              {(DQ (${ VSub_Name srcdir) (${ VSub_Name x))}
                                            )
                                          ]
                                          negated: T
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(__helpers_die)} {(DQ ($ VSub_DollarName '$myfail'))})
                                    (command.ControlFlow
                                      token: <ControlFlow_Return return>
                                      arg_word: {(1)}
                                    )
                                  ]
                                )
                              ]
                              redirects: [
                                (redir.Redir
                                  op: <Redir_Less '<'>
                                  fd: 16777215
                                  arg_word: 
                                    {
                                      (command_sub
                                        left_token: <Left_ProcSubIn '<('>
                                        command_list: 
                                          (command.CommandList
                                            children: [
                                              (command.Sentence
                                                child: (C {(KW_Set set)} {(Lit_Other '+') (x)})
                                                terminator: <Op_Semi ';'>
                                              )
                                              (command.WhileUntil
                                                keyword: <KW_While while>
                                                cond: [
                                                  (command.Sentence
                                                    child: (C {(true)})
                                                    terminator: <Op_Semi ';'>
                                                  )
                                                ]
                                                body: 
                                                  (command.DoGroup
                                                    children: [
                                                      (command.Sentence
                                                        child: 
                                                          (command.AndOr
                                                            ops: [Op_DPipe]
                                                            children: [
                                                              (C {(echo)} {(n)})
                                                              (command.ControlFlow
                                                                token: <ControlFlow_Break break>
                                                              )
                                                            ]
                                                          )
                                                        terminator: <Op_Semi ';'>
                                                      )
                                                    ]
                                                  )
                                              )
                                            ]
                                          )
                                      )
                                    }
                                )
                              ]
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(gz)} {(z)}]
                          action: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.AndOr
                                          ops: [Op_DAmp]
                                          children: [
                                            (C {(___eapi_unpack_is_case_sensitive)})
                                            (command.DBracket
                                              expr: 
                                                (bool_expr.Binary
                                                  op_id: BoolBinary_GlobNEqual
                                                  left: {(DQ (' gz z Z '))}
                                                  right: 
                                                    {(Lit_Other '*') 
                                                      (DQ (' ') (${ VSub_Name suffix) (' ')) (Lit_Other '*')
                                                    }
                                                )
                                            )
                                          ]
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(eqawarn)} {(DQ ('QA Notice: unpack called with'))} 
                                      {
                                        (DQ ("suffix '") (${ VSub_Name suffix) 
                                          ("' which is unofficially supported")
                                        )
                                      } {(DQ ("with EAPI '") (${ VSub_Name EAPI) ("'. Instead use 'gz', 'z', or 'Z'."))}
                                    )
                                  ]
                                )
                              ]
                            )
                            (command.AndOr
                              ops: [Op_DPipe]
                              children: [
                                (C {(__unpack_tar)} {(DQ ('gzip -d'))})
                                (command.ControlFlow
                                  token: <ControlFlow_Return return>
                                  arg_word: {(1)}
                                )
                              ]
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(bz2)} {(bz)}]
                          action: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.AndOr
                                          ops: [Op_DAmp]
                                          children: [
                                            (C {(___eapi_unpack_is_case_sensitive)})
                                            (command.DBracket
                                              expr: 
                                                (bool_expr.Binary
                                                  op_id: BoolBinary_GlobNEqual
                                                  left: {(DQ (' bz bz2 '))}
                                                  right: 
                                                    {(Lit_Other '*') 
                                                      (DQ (' ') (${ VSub_Name suffix) (' ')) (Lit_Other '*')
                                                    }
                                                )
                                            )
                                          ]
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(eqawarn)} {(DQ ('QA Notice: unpack called with'))} 
                                      {
                                        (DQ ("suffix '") (${ VSub_Name suffix) 
                                          ("' which is unofficially supported")
                                        )
                                      } {(DQ ("with EAPI '") (${ VSub_Name EAPI) ("'. Instead use 'bz' or 'bz2'."))}
                                    )
                                  ]
                                )
                              ]
                            )
                            (command.AndOr
                              ops: [Op_DPipe]
                              children: [
                                (C {(__unpack_tar)} 
                                  {
                                    (DQ 
                                      (braced_var_sub
                                        token: <VSub_Name PORTAGE_BUNZIP2_COMMAND>
                                        suffix_op: 
                                          (suffix_op.Unary
                                            op_id: VTest_ColonHyphen
                                            arg_word: {(${ VSub_Name PORTAGE_BZIP2_COMMAND) (' -d')}
                                          )
                                      )
                                    )
                                  }
                                )
                                (command.ControlFlow
                                  token: <ControlFlow_Return return>
                                  arg_word: {(1)}
                                )
                              ]
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(7z)}]
                          action: [
                            (C {(local)} {(my_output)})
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:my_output)
                                  op: Equal
                                  rhs: 
                                    {
                                      (DQ 
                                        (command_sub
                                          left_token: <Left_DollarParen '$('>
                                          command_list: 
                                            (command.CommandList
                                              children: [
                                                (C {(7z)} {(x)} {(-y)} 
                                                  {(DQ (${ VSub_Name srcdir) (${ VSub_Name x))}
                                                )
                                              ]
                                            )
                                        )
                                      )
                                    }
                                )
                              ]
                            )
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (C {(Lit_LBracket '[')} {($ VSub_QMark '$?')} {(-ne)} {(0)} 
                                          {(Lit_RBracket ']')}
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (command.Simple
                                      words: [{(echo)} {(DQ (${ VSub_Name my_output))}]
                                      redirects: [
                                        (redir.Redir
                                          op: <Redir_GreatAnd '>&'>
                                          fd: 16777215
                                          arg_word: {(2)}
                                        )
                                      ]
                                    )
                                    (C {(die)} {(DQ ($ VSub_DollarName '$myfail'))})
                                  ]
                                )
                              ]
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(rar)}]
                          action: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.AndOr
                                          ops: [Op_DAmp]
                                          children: [
                                            (C {(___eapi_unpack_is_case_sensitive)})
                                            (command.DBracket
                                              expr: 
                                                (bool_expr.Binary
                                                  op_id: BoolBinary_GlobNEqual
                                                  left: {(DQ (' rar RAR '))}
                                                  right: 
                                                    {(Lit_Other '*') 
                                                      (DQ (' ') (${ VSub_Name suffix) (' ')) (Lit_Other '*')
                                                    }
                                                )
                                            )
                                          ]
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(eqawarn)} {(DQ ('QA Notice: unpack called with'))} 
                                      {
                                        (DQ ("suffix '") (${ VSub_Name suffix) 
                                          ("' which is unofficially supported")
                                        )
                                      } {(DQ ("with EAPI '") (${ VSub_Name EAPI) ("'. Instead use 'rar' or 'RAR'."))}
                                    )
                                  ]
                                )
                              ]
                            )
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.Pipeline
                                          children: [
                                            (C {(unrar)} {(x)} {(-idq)} {(-o) (Lit_Other '+')} 
                                              {(DQ (${ VSub_Name srcdir) (${ VSub_Name x))}
                                            )
                                          ]
                                          negated: T
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(__helpers_die)} {(DQ ($ VSub_DollarName '$myfail'))})
                                    (command.ControlFlow
                                      token: <ControlFlow_Return return>
                                      arg_word: {(1)}
                                    )
                                  ]
                                )
                              ]
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(lha)} {(lzh)}]
                          action: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.AndOr
                                          ops: [Op_DAmp]
                                          children: [
                                            (C {(___eapi_unpack_is_case_sensitive)})
                                            (command.DBracket
                                              expr: 
                                                (bool_expr.Binary
                                                  op_id: BoolBinary_GlobNEqual
                                                  left: {(DQ (' LHA LHa lha lzh '))}
                                                  right: 
                                                    {(Lit_Other '*') 
                                                      (DQ (' ') (${ VSub_Name suffix) (' ')) (Lit_Other '*')
                                                    }
                                                )
                                            )
                                          ]
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(eqawarn)} {(DQ ('QA Notice: unpack called with'))} 
                                      {
                                        (DQ ("suffix '") (${ VSub_Name suffix) 
                                          ("' which is unofficially supported")
                                        )
                                      } {(DQ ("with EAPI '") (${ VSub_Name EAPI) ("'."))} {(DQ ("Instead use 'LHA', 'LHa', 'lha', or 'lzh'."))}
                                    )
                                  ]
                                )
                              ]
                            )
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.Pipeline
                                          children: [
                                            (C {(lha)} {(xfq)} 
                                              {(DQ (${ VSub_Name srcdir) (${ VSub_Name x))}
                                            )
                                          ]
                                          negated: T
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(__helpers_die)} {(DQ ($ VSub_DollarName '$myfail'))})
                                    (command.ControlFlow
                                      token: <ControlFlow_Return return>
                                      arg_word: {(1)}
                                    )
                                  ]
                                )
                              ]
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(a)}]
                          action: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.AndOr
                                          ops: [Op_DAmp]
                                          children: [
                                            (C {(___eapi_unpack_is_case_sensitive)})
                                            (command.DBracket
                                              expr: 
                                                (bool_expr.Binary
                                                  op_id: BoolBinary_GlobNEqual
                                                  left: {(DQ (' a '))}
                                                  right: 
                                                    {(Lit_Other '*') 
                                                      (DQ (' ') (${ VSub_Name suffix) (' ')) (Lit_Other '*')
                                                    }
                                                )
                                            )
                                          ]
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(eqawarn)} {(DQ ('QA Notice: unpack called with'))} 
                                      {
                                        (DQ ("suffix '") (${ VSub_Name suffix) 
                                          ("' which is unofficially supported")
                                        )
                                      } {(DQ ("with EAPI '") (${ VSub_Name EAPI) ("'. Instead use 'a'."))}
                                    )
                                  ]
                                )
                              ]
                            )
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.Pipeline
                                          children: [
                                            (C {(ar)} {(x)} {(DQ (${ VSub_Name srcdir) (${ VSub_Name x))})
                                          ]
                                          negated: T
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(__helpers_die)} {(DQ ($ VSub_DollarName '$myfail'))})
                                    (command.ControlFlow
                                      token: <ControlFlow_Return return>
                                      arg_word: {(1)}
                                    )
                                  ]
                                )
                              ]
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(deb)}]
                          action: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.AndOr
                                          ops: [Op_DAmp]
                                          children: [
                                            (C {(___eapi_unpack_is_case_sensitive)})
                                            (command.DBracket
                                              expr: 
                                                (bool_expr.Binary
                                                  op_id: BoolBinary_GlobNEqual
                                                  left: {(DQ (' deb '))}
                                                  right: 
                                                    {(Lit_Other '*') 
                                                      (DQ (' ') (${ VSub_Name suffix) (' ')) (Lit_Other '*')
                                                    }
                                                )
                                            )
                                          ]
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(eqawarn)} {(DQ ('QA Notice: unpack called with'))} 
                                      {
                                        (DQ ("suffix '") (${ VSub_Name suffix) 
                                          ("' which is unofficially supported")
                                        )
                                      } {(DQ ("with EAPI '") (${ VSub_Name EAPI) ("'. Instead use 'deb'."))}
                                    )
                                  ]
                                )
                              ]
                            )
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.AndOr
                                          ops: [Op_DAmp]
                                          children: [
                                            (command.DBracket
                                              expr: 
                                                (bool_expr.Binary
                                                  op_id: BoolBinary_GlobNEqual
                                                  left: 
                                                    {
                                                      (command_sub
                                                        left_token: <Left_DollarParen '$('>
                                                        command_list: 
                                                          (command.CommandList
                                                            children: [
                                                              (command.Simple
                                                                words: [{(ar)} {(--version)}]
                                                                redirects: [
                                                                  (redir.Redir
                                                                    op: <Redir_Great '2>'>
                                                                    fd: 2
                                                                    arg_word: {(/dev/null)}
                                                                  )
                                                                ]
                                                              )
                                                            ]
                                                          )
                                                      )
                                                    }
                                                  right: {(DQ ('GNU ar')) (Lit_Other '*')}
                                                )
                                            )
                                            (command.Simple
                                              words: [{(type)} {(-P)} {(deb2targz)}]
                                              redirects: [
                                                (redir.Redir
                                                  op: <Redir_Great '>'>
                                                  fd: 16777215
                                                  arg_word: {(/dev/null)}
                                                )
                                              ]
                                            )
                                          ]
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (command.ShAssignment
                                      pairs: [
                                        (assign_pair
                                          lhs: (sh_lhs_expr.Name name:y)
                                          op: Equal
                                          rhs: 
                                            {
                                              (braced_var_sub
                                                token: <VSub_Name x>
                                                suffix_op: 
                                                  (suffix_op.Unary
                                                    op_id: VOp1_DPound
                                                    arg_word: {('*') (Lit_Slash /)}
                                                  )
                                              )
                                            }
                                        )
                                      ]
                                    )
                                    (C {(local)} {(Lit_VarLike 'created_symlink=') (0)})
                                    (command.If
                                      arms: [
                                        (if_arm
                                          cond: [
                                            (command.Sentence
                                              child: 
                                                (C {(Lit_LBracket '[')} {(KW_Bang '!')} 
                                                  {
                                                    (DQ ($ VSub_DollarName '$srcdir') 
                                                      ($ VSub_DollarName '$x')
                                                    )
                                                  } {(-ef)} {(DQ ($ VSub_DollarName '$y'))} {(Lit_RBracket ']')}
                                                )
                                              terminator: <Op_Semi ';'>
                                            )
                                          ]
                                          action: [
                                            (command.If
                                              arms: [
                                                (if_arm
                                                  cond: [
                                                    (command.Sentence
                                                      child: 
                                                        (command.Pipeline
                                                          children: [
                                                            (C {(ln)} {(-sf)} 
                                                              {
                                                                (DQ ($ VSub_DollarName '$srcdir') 
                                                                  ($ VSub_DollarName '$x')
                                                                )
                                                              } {(DQ ($ VSub_DollarName '$y'))}
                                                            )
                                                          ]
                                                          negated: T
                                                        )
                                                      terminator: <Op_Semi ';'>
                                                    )
                                                  ]
                                                  action: [
                                                    (C {(__helpers_die)} 
                                                      {(DQ ($ VSub_DollarName '$myfail'))}
                                                    )
                                                    (command.ControlFlow
                                                      token: <ControlFlow_Return return>
                                                      arg_word: {(1)}
                                                    )
                                                  ]
                                                )
                                              ]
                                            )
                                            (command.ShAssignment
                                              pairs: [
                                                (assign_pair
                                                  lhs: (sh_lhs_expr.Name name:created_symlink)
                                                  op: Equal
                                                  rhs: {(1)}
                                                )
                                              ]
                                            )
                                          ]
                                        )
                                      ]
                                    )
                                    (command.If
                                      arms: [
                                        (if_arm
                                          cond: [
                                            (command.Sentence
                                              child: 
                                                (command.Pipeline
                                                  children: [
                                                    (C {(deb2targz)} {(DQ ($ VSub_DollarName '$y'))})
                                                  ]
                                                  negated: T
                                                )
                                              terminator: <Op_Semi ';'>
                                            )
                                          ]
                                          action: [
                                            (C {(__helpers_die)} {(DQ ($ VSub_DollarName '$myfail'))})
                                            (command.ControlFlow
                                              token: <ControlFlow_Return return>
                                              arg_word: {(1)}
                                            )
                                          ]
                                        )
                                      ]
                                    )
                                    (command.If
                                      arms: [
                                        (if_arm
                                          cond: [
                                            (command.Sentence
                                              child: 
                                                (C {(Lit_LBracket '[')} 
                                                  {($ VSub_DollarName '$created_symlink')} {(Lit_Equals '=')} {(1)} {(Lit_RBracket ']')}
                                                )
                                              terminator: <Op_Semi ';'>
                                            )
                                          ]
                                          action: [(C {(rm)} {(-f)} {(DQ ($ VSub_DollarName '$y'))})]
                                        )
                                      ]
                                    )
                                    (command.If
                                      arms: [
                                        (if_arm
                                          cond: [
                                            (command.Sentence
                                              child: 
                                                (command.Pipeline
                                                  children: [
                                                    (C {(mv)} {(-f)} 
                                                      {
                                                        (DQ 
                                                          (braced_var_sub
                                                            token: <VSub_Name y>
                                                            suffix_op: 
                                                              (suffix_op.Unary
                                                                op_id: VOp1_Percent
                                                                arg_word: {(.deb)}
                                                              )
                                                          )
                                                        ) (.tar.gz)
                                                      } {(data.tar.gz)}
                                                    )
                                                  ]
                                                  negated: T
                                                )
                                              terminator: <Op_Semi ';'>
                                            )
                                          ]
                                          action: [
                                            (command.If
                                              arms: [
                                                (if_arm
                                                  cond: [
                                                    (command.Sentence
                                                      child: 
                                                        (command.Pipeline
                                                          children: [
                                                            (C {(mv)} {(-f)} 
                                                              {
                                                                (DQ 
                                                                  (braced_var_sub
                                                                    token: <VSub_Name y>
                                                                    suffix_op: 
                                                                      (suffix_op.Unary
                                                                        op_id: VOp1_Percent
                                                                        arg_word: {(.deb)}
                                                                      )
                                                                  )
                                                                ) (.tar.xz)
                                                              } {(data.tar.xz)}
                                                            )
                                                          ]
                                                          negated: T
                                                        )
                                                      terminator: <Op_Semi ';'>
                                                    )
                                                  ]
                                                  action: [
                                                    (C {(__helpers_die)} 
                                                      {(DQ ($ VSub_DollarName '$myfail'))}
                                                    )
                                                    (command.ControlFlow
                                                      token: <ControlFlow_Return return>
                                                      arg_word: {(1)}
                                                    )
                                                  ]
                                                )
                                              ]
                                            )
                                          ]
                                        )
                                      ]
                                    )
                                  ]
                                )
                              ]
                              else_action: [
                                (command.If
                                  arms: [
                                    (if_arm
                                      cond: [
                                        (command.Sentence
                                          child: 
                                            (command.Pipeline
                                              children: [
                                                (C {(ar)} {(x)} 
                                                  {
                                                    (DQ ($ VSub_DollarName '$srcdir') 
                                                      ($ VSub_DollarName '$x')
                                                    )
                                                  }
                                                )
                                              ]
                                              negated: T
                                            )
                                          terminator: <Op_Semi ';'>
                                        )
                                      ]
                                      action: [
                                        (C {(__helpers_die)} {(DQ ($ VSub_DollarName '$myfail'))})
                                        (command.ControlFlow
                                          token: <ControlFlow_Return return>
                                          arg_word: {(1)}
                                        )
                                      ]
                                    )
                                  ]
                                )
                              ]
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(lzma)}]
                          action: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.AndOr
                                          ops: [Op_DAmp]
                                          children: [
                                            (C {(___eapi_unpack_is_case_sensitive)})
                                            (command.DBracket
                                              expr: 
                                                (bool_expr.Binary
                                                  op_id: BoolBinary_GlobNEqual
                                                  left: {(DQ (' lzma '))}
                                                  right: 
                                                    {(Lit_Other '*') 
                                                      (DQ (' ') (${ VSub_Name suffix) (' ')) (Lit_Other '*')
                                                    }
                                                )
                                            )
                                          ]
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(eqawarn)} {(DQ ('QA Notice: unpack called with'))} 
                                      {
                                        (DQ ("suffix '") (${ VSub_Name suffix) 
                                          ("' which is unofficially supported")
                                        )
                                      } {(DQ ("with EAPI '") (${ VSub_Name EAPI) ("'. Instead use 'lzma'."))}
                                    )
                                  ]
                                )
                              ]
                            )
                            (command.AndOr
                              ops: [Op_DPipe]
                              children: [
                                (C {(__unpack_tar)} {(DQ ('lzma -d'))})
                                (command.ControlFlow
                                  token: <ControlFlow_Return return>
                                  arg_word: {(1)}
                                )
                              ]
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(xz)}]
                          action: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.AndOr
                                          ops: [Op_DAmp]
                                          children: [
                                            (C {(___eapi_unpack_is_case_sensitive)})
                                            (command.DBracket
                                              expr: 
                                                (bool_expr.Binary
                                                  op_id: BoolBinary_GlobNEqual
                                                  left: {(DQ (' xz '))}
                                                  right: 
                                                    {(Lit_Other '*') 
                                                      (DQ (' ') (${ VSub_Name suffix) (' ')) (Lit_Other '*')
                                                    }
                                                )
                                            )
                                          ]
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(eqawarn)} {(DQ ('QA Notice: unpack called with'))} 
                                      {
                                        (DQ ("suffix '") (${ VSub_Name suffix) 
                                          ("' which is unofficially supported")
                                        )
                                      } {(DQ ("with EAPI '") (${ VSub_Name EAPI) ("'. Instead use 'xz'."))}
                                    )
                                  ]
                                )
                              ]
                            )
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: (C {(___eapi_unpack_supports_xz)})
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (command.AndOr
                                      ops: [Op_DPipe]
                                      children: [
                                        (C {(__unpack_tar)} {(DQ ('xz -d'))})
                                        (command.ControlFlow
                                          token: <ControlFlow_Return return>
                                          arg_word: {(1)}
                                        )
                                      ]
                                    )
                                  ]
                                )
                              ]
                              else_action: [
                                (C {(__vecho)} 
                                  {
                                    (DQ ('unpack ') (${ VSub_Name x) 
                                      (': file format not recognized. Ignoring.')
                                    )
                                  }
                                )
                              ]
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(txz)}]
                          action: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.AndOr
                                          ops: [Op_DAmp]
                                          children: [
                                            (C {(___eapi_unpack_is_case_sensitive)})
                                            (command.DBracket
                                              expr: 
                                                (bool_expr.Binary
                                                  op_id: BoolBinary_GlobNEqual
                                                  left: {(DQ (' txz '))}
                                                  right: 
                                                    {(Lit_Other '*') 
                                                      (DQ (' ') (${ VSub_Name suffix) (' ')) (Lit_Other '*')
                                                    }
                                                )
                                            )
                                          ]
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(eqawarn)} {(DQ ('QA Notice: unpack called with'))} 
                                      {
                                        (DQ ("suffix '") (${ VSub_Name suffix) 
                                          ("' which is unofficially supported")
                                        )
                                      } {(DQ ("with EAPI '") (${ VSub_Name EAPI) ("'. Instead use 'txz'."))}
                                    )
                                  ]
                                )
                              ]
                            )
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: (C {(___eapi_unpack_supports_txz)})
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (command.If
                                      arms: [
                                        (if_arm
                                          cond: [
                                            (command.Sentence
                                              child: 
                                                (command.Pipeline
                                                  children: [
                                                    (C {(tar)} {(xof)} 
                                                      {
                                                        (DQ ($ VSub_DollarName '$srcdir') 
                                                          ($ VSub_DollarName '$x')
                                                        )
                                                      }
                                                    )
                                                  ]
                                                  negated: T
                                                )
                                              terminator: <Op_Semi ';'>
                                            )
                                          ]
                                          action: [
                                            (C {(__helpers_die)} {(DQ ($ VSub_DollarName '$myfail'))})
                                            (command.ControlFlow
                                              token: <ControlFlow_Return return>
                                              arg_word: {(1)}
                                            )
                                          ]
                                        )
                                      ]
                                    )
                                  ]
                                )
                              ]
                              else_action: [
                                (C {(__vecho)} 
                                  {
                                    (DQ ('unpack ') (${ VSub_Name x) 
                                      (': file format not recognized. Ignoring.')
                                    )
                                  }
                                )
                              ]
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(Lit_Star '*')}]
                          action: [
                            (C {(__vecho)} 
                              {
                                (DQ ('unpack ') (${ VSub_Name x) 
                                  (': file format not recognized. Ignoring.')
                                )
                              }
                            )
                          ]
                        )
                      ]
                    )
                  ]
                )
            )
            (command.Pipeline
              children: [
                (C {(find)} {(.)} {(-mindepth)} {(1)} {(-maxdepth)} {(1)} {(KW_Bang '!')} {(-type)} {(l)} 
                  {(-print0)}
                )
                (C {(${ VSub_Name XARGS)} {(-0)} {(DQ (${ VSub_Name PORTAGE_BIN_PATH) (/chmod-lite))})
              ]
              negated: F
            )
          ]
        )
    )
    (command.ShFunction
      name: econf
      body: 
        (command.BraceGroup
          children: [
            (C {(local)} {(x)})
            (C {(local)} 
              {(Lit_VarLike 'pid=') 
                (braced_var_sub
                  token: <VSub_Name BASHPID>
                  suffix_op: 
                    (suffix_op.Unary
                      op_id: VTest_ColonHyphen
                      arg_word: 
                        {
                          (command_sub
                            left_token: <Left_DollarParen '$('>
                            command_list: (command.CommandList children:[(C {(__bashpid)})])
                          )
                        }
                    )
                )
              }
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.Pipeline
                          children: [(C {(___eapi_has_prefix_variables)})]
                          negated: T
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [(C {(local)} {(Lit_VarLike 'EPREFIX=')})]
                )
              ]
            )
            (command.ShFunction
              name: __hasg
              body: 
                (command.BraceGroup
                  children: [
                    (C {(local)} {(x)} {(Lit_VarLike 's=') ($ VSub_Number '$1')})
                    (C {(shift)})
                    (command.ForEach
                      iter_name: x
                      do_arg_iter: T
                      body: 
                        (command.DoGroup
                          children: [
                            (command.Sentence
                              child: 
                                (command.AndOr
                                  ops: [Op_DAmp Op_DAmp]
                                  children: [
                                    (command.DBracket
                                      expr: 
                                        (bool_expr.Binary
                                          op_id: BoolBinary_GlobDEqual
                                          left: {(${ VSub_Name x)}
                                          right: {(${ VSub_Name s)}
                                        )
                                    )
                                    (C {(echo)} {(DQ (${ VSub_Name x))})
                                    (command.ControlFlow
                                      token: <ControlFlow_Return return>
                                      arg_word: {(0)}
                                    )
                                  ]
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                        )
                    )
                    (command.ControlFlow
                      token: <ControlFlow_Return return>
                      arg_word: {(1)}
                    )
                  ]
                )
            )
            (command.ShFunction
              name: __hasgq
              body: 
                (command.BraceGroup
                  children: [
                    (command.Sentence
                      child: 
                        (command.Simple
                          words: [{(__hasg)} {(DQ ($ VSub_At '$@'))}]
                          redirects: [
                            (redir.Redir
                              op: <Redir_Great '>'>
                              fd: 16777215
                              arg_word: {(/dev/null)}
                            )
                          ]
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                )
            )
            (C {(local)} 
              {(Lit_VarLike 'phase_func=') 
                (command_sub
                  left_token: <Left_DollarParen '$('>
                  command_list: 
                    (command.CommandList
                      children: [
                        (C {(__ebuild_arg_to_phase)} {(DQ ($ VSub_DollarName '$EBUILD_PHASE'))})
                      ]
                    )
                )
              }
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.DBracket
                          expr: 
                            (bool_expr.Unary
                              op_id: BoolUnary_n
                              child: {($ VSub_DollarName '$phase_func')}
                            )
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.Pipeline
                                  children: [(C {(___eapi_has_src_configure)})]
                                  negated: T
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (command.AndOr
                              ops: [Op_DAmp]
                              children: [
                                (command.DBracket
                                  expr: 
                                    (bool_expr.Binary
                                      op_id: BoolBinary_GlobNEqual
                                      left: {($ VSub_DollarName '$phase_func')}
                                      right: {(src_compile)}
                                    )
                                )
                                (C {(eqawarn)} {(DQ ('QA Notice: econf called in'))} 
                                  {(DQ ($ VSub_DollarName '$phase_func') (' instead of src_compile'))}
                                )
                              ]
                            )
                          ]
                        )
                      ]
                      else_action: [
                        (command.AndOr
                          ops: [Op_DAmp]
                          children: [
                            (command.DBracket
                              expr: 
                                (bool_expr.Binary
                                  op_id: BoolBinary_GlobNEqual
                                  left: {($ VSub_DollarName '$phase_func')}
                                  right: {(src_configure)}
                                )
                            )
                            (C {(eqawarn)} {(DQ ('QA Notice: econf called in'))} 
                              {(DQ ($ VSub_DollarName '$phase_func') (' instead of src_configure'))}
                            )
                          ]
                        )
                      ]
                    )
                  ]
                )
              ]
            )
            (C {(Lit_Other ':')} 
              {
                (braced_var_sub
                  token: <VSub_Name ECONF_SOURCE>
                  suffix_op: (suffix_op.Unary op_id:VTest_ColonEquals arg_word:{(.)})
                )
              }
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (C {(Lit_LBracket '[')} {(-x)} {(DQ (${ VSub_Name ECONF_SOURCE) (/configure))} 
                          {(Lit_RBracket ']')}
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.DBracket
                                  expr: 
                                    (bool_expr.LogicalAnd
                                      left: 
                                        (bool_expr.Unary
                                          op_id: BoolUnary_n
                                          child: {($ VSub_DollarName '$CONFIG_SHELL')}
                                        )
                                      right: 
                                        (bool_expr.Binary
                                          op_id: BoolBinary_EqualTilde
                                          left: 
                                            {
                                              (DQ 
                                                (command_sub
                                                  left_token: <Left_DollarParen '$('>
                                                  command_list: 
                                                    (command.CommandList
                                                      children: [
                                                        (C {(head)} {(-n1)} 
                                                          {
                                                            (DQ ($ VSub_DollarName '$ECONF_SOURCE') 
                                                              (/configure)
                                                            )
                                                          }
                                                        )
                                                      ]
                                                    )
                                                )
                                              )
                                            }
                                          right: 
                                            {(Lit_Other '^') (SQ <'#!'>) (Lit_Other '[') 
                                              (Lit_Other '[') (Lit_Other ':') (space) (Lit_Other ':') (Lit_Other ']') (Lit_Other ']') (Lit_Other '*') (/bin/sh) 
                                              (Lit_Other '(') (Lit_Other '[') (Lit_Other '[') (Lit_Other ':') (space) (Lit_Other ':') (Lit_Other ']') (Lit_Other ']') 
                                              (Lit_Other '|') (Lit_Other '$') (Lit_Other ')')
                                            }
                                        )
                                    )
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (command.AndOr
                              ops: [Op_DPipe]
                              children: [
                                (C {(cp)} {(-p)} {(DQ (${ VSub_Name ECONF_SOURCE) (/configure))} 
                                  {
                                    (DQ (${ VSub_Name ECONF_SOURCE) (/configure._portage_tmp_.) 
                                      (${ VSub_Name pid)
                                    )
                                  }
                                )
                                (C {(die)})
                              ]
                            )
                            (command.AndOr
                              ops: [Op_DPipe]
                              children: [
                                (C {(sed)} {(-i)} {(-e)} 
                                  {
                                    (DQ ('1s:^#![[:space:]]*/bin/sh:#!') 
                                      ($ VSub_DollarName '$CONFIG_SHELL') (':')
                                    )
                                  } {(DQ (${ VSub_Name ECONF_SOURCE) (/configure._portage_tmp_.) (${ VSub_Name pid))}
                                )
                                (C {(die)} 
                                  {
                                    (DQ ("Substition of shebang in '") (${ VSub_Name ECONF_SOURCE) 
                                      ("/configure' failed")
                                    )
                                  }
                                )
                              ]
                            )
                            (command.AndOr
                              ops: [Op_DPipe]
                              children: [
                                (C {(touch)} {(-r)} {(DQ (${ VSub_Name ECONF_SOURCE) (/configure))} 
                                  {
                                    (DQ (${ VSub_Name ECONF_SOURCE) (/configure._portage_tmp_.) 
                                      (${ VSub_Name pid)
                                    )
                                  }
                                )
                                (C {(die)})
                              ]
                            )
                            (command.AndOr
                              ops: [Op_DPipe]
                              children: [
                                (C {(mv)} {(-f)} 
                                  {
                                    (DQ (${ VSub_Name ECONF_SOURCE) (/configure._portage_tmp_.) 
                                      (${ VSub_Name pid)
                                    )
                                  } {(DQ (${ VSub_Name ECONF_SOURCE) (/configure))}
                                )
                                (C {(die)})
                              ]
                            )
                          ]
                        )
                      ]
                    )
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (C {(Lit_LBracket '[')} {(-e)} 
                                  {(DQ (${ VSub_Name EPREFIX)) (/usr/share/gnuconfig/)} {(Lit_RBracket ']')}
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (command.Pipeline
                              children: [
                                (C {(find)} {(DQ (${ VSub_Name WORKDIR))} {(-type)} {(f)} {(SQ <'('>)} 
                                  {(-name)} {(config.guess)} {(-o)} {(-name)} {(config.sub)} {(SQ <')'>)} {(-print0)}
                                )
                                (command.WhileUntil
                                  keyword: <KW_While while>
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (C {(read)} {(-r)} {(-d)} 
                                          {
                                            (single_quoted
                                              left: <Left_SingleQuoteC "$'">
                                              tokens: [<Char_OneChar '\\0'>]
                                            )
                                          } {(x)}
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  body: 
                                    (command.DoGroup
                                      children: [
                                        (C {(__vecho)} 
                                          {
                                            (DQ (' * econf: updating ') 
                                              (braced_var_sub
                                                token: <VSub_Name x>
                                                suffix_op: 
                                                  (suffix_op.PatSub
                                                    pat: 
                                                      {(${ VSub_Name WORKDIR) 
                                                        (word_part.EscapedLiteral
                                                          token: <Lit_EscapedChar '\\/'>
                                                        )
                                                      }
                                                    replace_mode: Undefined_Tok
                                                  )
                                              ) (' with ') (${ VSub_Name EPREFIX) (/usr/share/gnuconfig/) 
                                              (braced_var_sub
                                                token: <VSub_Name x>
                                                suffix_op: 
                                                  (suffix_op.Unary
                                                    op_id: VOp1_DPound
                                                    arg_word: {('*') (Lit_Slash /)}
                                                  )
                                              )
                                            )
                                          }
                                        )
                                        (C {(cp)} {(-f)} 
                                          {(DQ (${ VSub_Name EPREFIX)) (/usr/share/gnuconfig/) 
                                            (DQ 
                                              (braced_var_sub
                                                token: <VSub_Name x>
                                                suffix_op: 
                                                  (suffix_op.Unary
                                                    op_id: VOp1_DPound
                                                    arg_word: {('*') (Lit_Slash /)}
                                                  )
                                              )
                                            )
                                          } {(DQ (${ VSub_Name x) (.) (${ VSub_Name pid))}
                                        )
                                        (C {(mv)} {(-f)} {(DQ (${ VSub_Name x) (.) (${ VSub_Name pid))} 
                                          {(DQ (${ VSub_Name x))}
                                        )
                                      ]
                                    )
                                )
                              ]
                              negated: F
                            )
                          ]
                        )
                      ]
                    )
                    (C {(local)} {(Lit_VarLike 'conf_args=') (sh_array_literal left:<Op_LParen '('>)})
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.AndOr
                                  ops: [Op_DPipe Op_DPipe]
                                  children: [
                                    (C {(___eapi_econf_passes_--disable-dependency-tracking)})
                                    (C {(___eapi_econf_passes_--disable-silent-rules)})
                                    (C {(___eapi_econf_passes_--docdir_and_--htmldir)})
                                  ]
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (C {(local)} 
                              {(Lit_VarLike 'conf_help=') 
                                (command_sub
                                  left_token: <Left_DollarParen '$('>
                                  command_list: 
                                    (command.CommandList
                                      children: [
                                        (command.Simple
                                          words: [
                                            {(DQ (${ VSub_Name ECONF_SOURCE) (/configure))}
                                            {(--help)}
                                          ]
                                          redirects: [
                                            (redir.Redir
                                              op: <Redir_Great '2>'>
                                              fd: 2
                                              arg_word: {(/dev/null)}
                                            )
                                          ]
                                        )
                                      ]
                                    )
                                )
                              }
                            )
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: (C {(___eapi_econf_passes_--disable-dependency-tracking)})
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (command.If
                                      arms: [
                                        (if_arm
                                          cond: [
                                            (command.Sentence
                                              child: 
                                                (command.DBracket
                                                  expr: 
                                                    (bool_expr.Binary
                                                      op_id: BoolBinary_GlobDEqual
                                                      left: {(${ VSub_Name conf_help)}
                                                      right: 
                                                        {(Lit_Other '*') 
                                                          (--disable-dependency-tracking) (Lit_Other '*')
                                                        }
                                                    )
                                                )
                                              terminator: <Op_Semi ';'>
                                            )
                                          ]
                                          action: [
                                            (command.ShAssignment
                                              pairs: [
                                                (assign_pair
                                                  lhs: (sh_lhs_expr.Name name:conf_args)
                                                  op: PlusEqual
                                                  rhs: 
                                                    {
                                                      (sh_array_literal
                                                        left: <Op_LParen '('>
                                                        words: [{(--disable-dependency-tracking)}]
                                                      )
                                                    }
                                                )
                                              ]
                                            )
                                          ]
                                        )
                                      ]
                                    )
                                  ]
                                )
                              ]
                            )
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: (C {(___eapi_econf_passes_--disable-silent-rules)})
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (command.If
                                      arms: [
                                        (if_arm
                                          cond: [
                                            (command.Sentence
                                              child: 
                                                (command.DBracket
                                                  expr: 
                                                    (bool_expr.Binary
                                                      op_id: BoolBinary_GlobDEqual
                                                      left: {(${ VSub_Name conf_help)}
                                                      right: 
                                                        {(Lit_Other '*') (--disable-silent-rules) 
                                                          (Lit_Other '*')
                                                        }
                                                    )
                                                )
                                              terminator: <Op_Semi ';'>
                                            )
                                          ]
                                          action: [
                                            (command.ShAssignment
                                              pairs: [
                                                (assign_pair
                                                  lhs: (sh_lhs_expr.Name name:conf_args)
                                                  op: PlusEqual
                                                  rhs: 
                                                    {
                                                      (sh_array_literal
                                                        left: <Op_LParen '('>
                                                        words: [{(--disable-silent-rules)}]
                                                      )
                                                    }
                                                )
                                              ]
                                            )
                                          ]
                                        )
                                      ]
                                    )
                                  ]
                                )
                              ]
                            )
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: (C {(___eapi_econf_passes_--docdir_and_--htmldir)})
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (command.If
                                      arms: [
                                        (if_arm
                                          cond: [
                                            (command.Sentence
                                              child: 
                                                (command.DBracket
                                                  expr: 
                                                    (bool_expr.Binary
                                                      op_id: BoolBinary_GlobDEqual
                                                      left: {(${ VSub_Name conf_help)}
                                                      right: 
                                                        {(Lit_Other '*') (--docdir) (Lit_Other '*')}
                                                    )
                                                )
                                              terminator: <Op_Semi ';'>
                                            )
                                          ]
                                          action: [
                                            (command.ShAssignment
                                              pairs: [
                                                (assign_pair
                                                  lhs: (sh_lhs_expr.Name name:conf_args)
                                                  op: PlusEqual
                                                  rhs: 
                                                    {
                                                      (sh_array_literal
                                                        left: <Op_LParen '('>
                                                        words: [
                                                          {(--docdir) (Lit_Equals '=') 
                                                            (DQ (${ VSub_Name EPREFIX)) (/usr/share/doc/) (${ VSub_Name PF)
                                                          }
                                                        ]
                                                      )
                                                    }
                                                )
                                              ]
                                            )
                                          ]
                                        )
                                      ]
                                    )
                                    (command.If
                                      arms: [
                                        (if_arm
                                          cond: [
                                            (command.Sentence
                                              child: 
                                                (command.DBracket
                                                  expr: 
                                                    (bool_expr.Binary
                                                      op_id: BoolBinary_GlobDEqual
                                                      left: {(${ VSub_Name conf_help)}
                                                      right: 
                                                        {(Lit_Other '*') (--htmldir) (Lit_Other '*')}
                                                    )
                                                )
                                              terminator: <Op_Semi ';'>
                                            )
                                          ]
                                          action: [
                                            (command.ShAssignment
                                              pairs: [
                                                (assign_pair
                                                  lhs: (sh_lhs_expr.Name name:conf_args)
                                                  op: PlusEqual
                                                  rhs: 
                                                    {
                                                      (sh_array_literal
                                                        left: <Op_LParen '('>
                                                        words: [
                                                          {(--htmldir) (Lit_Equals '=') 
                                                            (DQ (${ VSub_Name EPREFIX)) (/usr/share/doc/) (${ VSub_Name PF) (/html)
                                                          }
                                                        ]
                                                      )
                                                    }
                                                )
                                              ]
                                            )
                                          ]
                                        )
                                      ]
                                    )
                                  ]
                                )
                              ]
                            )
                          ]
                        )
                      ]
                    )
                    (C {(local)} {(CONF_LIBDIR)} 
                      {(Lit_VarLike 'LIBDIR_VAR=') (DQ (LIBDIR_) (${ VSub_Name ABI))}
                    )
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.DBracket
                                  expr: 
                                    (bool_expr.LogicalAnd
                                      left: 
                                        (bool_expr.Unary
                                          op_id: BoolUnary_n
                                          child: {(${ VSub_Name ABI)}
                                        )
                                      right: 
                                        (bool_expr.Unary
                                          op_id: BoolUnary_n
                                          child: 
                                            {
                                              (braced_var_sub
                                                token: <VSub_Name LIBDIR_VAR>
                                                prefix_op: VSub_Bang
                                              )
                                            }
                                        )
                                    )
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:CONF_LIBDIR)
                                  op: Equal
                                  rhs: 
                                    {
                                      (braced_var_sub
                                        token: <VSub_Name LIBDIR_VAR>
                                        prefix_op: VSub_Bang
                                      )
                                    }
                                )
                              ]
                            )
                          ]
                        )
                      ]
                    )
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.AndOr
                                  ops: [Op_DAmp]
                                  children: [
                                    (command.DBracket
                                      expr: 
                                        (bool_expr.Unary
                                          op_id: BoolUnary_n
                                          child: {(${ VSub_Name CONF_LIBDIR)}
                                        )
                                    )
                                    (command.Pipeline
                                      children: [
                                        (C {(__hasgq)} 
                                          {(--libdir) (Lit_Equals '=') 
                                            (word_part.EscapedLiteral
                                              token: <Lit_EscapedChar '\\*'>
                                            )
                                          } {(DQ ($ VSub_At '$@'))}
                                        )
                                      ]
                                      negated: T
                                    )
                                  ]
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (C {(export)} 
                              {(Lit_VarLike 'CONF_PREFIX=') 
                                (command_sub
                                  left_token: <Left_DollarParen '$('>
                                  command_list: 
                                    (command.CommandList
                                      children: [
                                        (C {(__hasg)} 
                                          {(--exec-prefix) (Lit_Equals '=') 
                                            (word_part.EscapedLiteral
                                              token: <Lit_EscapedChar '\\*'>
                                            )
                                          } {(DQ ($ VSub_At '$@'))}
                                        )
                                      ]
                                    )
                                )
                              }
                            )
                            (command.AndOr
                              ops: [Op_DAmp]
                              children: [
                                (command.DBracket
                                  expr: 
                                    (bool_expr.Unary
                                      op_id: BoolUnary_z
                                      child: {(${ VSub_Name CONF_PREFIX)}
                                    )
                                )
                                (command.ShAssignment
                                  pairs: [
                                    (assign_pair
                                      lhs: (sh_lhs_expr.Name name:CONF_PREFIX)
                                      op: Equal
                                      rhs: 
                                        {
                                          (command_sub
                                            left_token: <Left_DollarParen '$('>
                                            command_list: 
                                              (command.CommandList
                                                children: [
                                                  (C {(__hasg)} 
                                                    {(--prefix) (Lit_Equals '=') 
                                                      (word_part.EscapedLiteral
                                                        token: <Lit_EscapedChar '\\*'>
                                                      )
                                                    } {(DQ ($ VSub_At '$@'))}
                                                  )
                                                ]
                                              )
                                          )
                                        }
                                    )
                                  ]
                                )
                              ]
                            )
                            (C {(Lit_Other ':')} 
                              {
                                (braced_var_sub
                                  token: <VSub_Name CONF_PREFIX>
                                  suffix_op: 
                                    (suffix_op.Unary
                                      op_id: VTest_ColonEquals
                                      arg_word: {(${ VSub_Name EPREFIX) (Lit_Slash /) (usr)}
                                    )
                                )
                              }
                            )
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:CONF_PREFIX)
                                  op: Equal
                                  rhs: 
                                    {
                                      (braced_var_sub
                                        token: <VSub_Name CONF_PREFIX>
                                        suffix_op: (suffix_op.Unary op_id:VOp1_Pound arg_word:{('*=')})
                                      )
                                    }
                                )
                              ]
                            )
                            (command.AndOr
                              ops: [Op_DAmp]
                              children: [
                                (command.DBracket
                                  expr: 
                                    (bool_expr.Binary
                                      op_id: BoolBinary_GlobNEqual
                                      left: {(${ VSub_Name CONF_PREFIX)}
                                      right: {(/) (Lit_Other '*')}
                                    )
                                )
                                (command.ShAssignment
                                  pairs: [
                                    (assign_pair
                                      lhs: (sh_lhs_expr.Name name:CONF_PREFIX)
                                      op: Equal
                                      rhs: {(DQ (/) (${ VSub_Name CONF_PREFIX))}
                                    )
                                  ]
                                )
                              ]
                            )
                            (command.AndOr
                              ops: [Op_DAmp]
                              children: [
                                (command.DBracket
                                  expr: 
                                    (bool_expr.Binary
                                      op_id: BoolBinary_GlobNEqual
                                      left: {(${ VSub_Name CONF_LIBDIR)}
                                      right: {(/) (Lit_Other '*')}
                                    )
                                )
                                (command.ShAssignment
                                  pairs: [
                                    (assign_pair
                                      lhs: (sh_lhs_expr.Name name:CONF_LIBDIR)
                                      op: Equal
                                      rhs: {(DQ (/) (${ VSub_Name CONF_LIBDIR))}
                                    )
                                  ]
                                )
                              ]
                            )
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:conf_args)
                                  op: PlusEqual
                                  rhs: 
                                    {
                                      (sh_array_literal
                                        left: <Op_LParen '('>
                                        words: [
                                          {(--libdir) (Lit_Equals '=') 
                                            (DQ 
                                              (command_sub
                                                left_token: <Left_DollarParen '$('>
                                                command_list: 
                                                  (command.CommandList
                                                    children: [
                                                      (C {(__strip_duplicate_slashes)} 
                                                        {
                                                          (DQ (${ VSub_Name CONF_PREFIX) 
                                                            (${ VSub_Name CONF_LIBDIR)
                                                          )
                                                        }
                                                      )
                                                    ]
                                                  )
                                              )
                                            )
                                          }
                                        ]
                                      )
                                    }
                                )
                              ]
                            )
                          ]
                        )
                      ]
                    )
                    (C {(eval)} {(DQ ('local -a EXTRA_ECONF=(') (${ VSub_Name EXTRA_ECONF) (')'))})
                    (C {(KW_Set set)} {(--)} 
                      {(--prefix) (Lit_Equals '=') (DQ (${ VSub_Name EPREFIX)) (/usr)} 
                      {
                        (braced_var_sub
                          token: <VSub_Name CBUILD>
                          suffix_op: 
                            (suffix_op.Unary
                              op_id: VTest_ColonPlus
                              arg_word: {('--build=') (${ VSub_Name CBUILD)}
                            )
                        )
                      } {(--host) (Lit_Equals '=') (${ VSub_Name CHOST)} 
                      {
                        (braced_var_sub
                          token: <VSub_Name CTARGET>
                          suffix_op: 
                            (suffix_op.Unary
                              op_id: VTest_ColonPlus
                              arg_word: {('--target=') (${ VSub_Name CTARGET)}
                            )
                        )
                      } {(--mandir) (Lit_Equals '=') (DQ (${ VSub_Name EPREFIX)) (/usr/share/man)} 
                      {(--infodir) (Lit_Equals '=') (DQ (${ VSub_Name EPREFIX)) (/usr/share/info)} {(--datadir) (Lit_Equals '=') (DQ (${ VSub_Name EPREFIX)) (/usr/share)} 
                      {(--sysconfdir) (Lit_Equals '=') (DQ (${ VSub_Name EPREFIX)) (/etc)} {(--localstatedir) (Lit_Equals '=') (DQ (${ VSub_Name EPREFIX)) (/var/lib)} 
                      {
                        (DQ 
                          (braced_var_sub
                            token: <VSub_Name conf_args>
                            bracket_op: (bracket_op.WholeArray op_id:Lit_At)
                          )
                        )
                      } {(DQ ($ VSub_At '$@'))} 
                      {
                        (DQ 
                          (braced_var_sub
                            token: <VSub_Name EXTRA_ECONF>
                            bracket_op: (bracket_op.WholeArray op_id:Lit_At)
                          )
                        )
                      }
                    )
                    (C {(__vecho)} {(DQ (${ VSub_Name ECONF_SOURCE) (/configure))} 
                      {(DQ ($ VSub_At '$@'))}
                    )
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.Pipeline
                                  children: [
                                    (C {(DQ (${ VSub_Name ECONF_SOURCE) (/configure))} 
                                      {(DQ ($ VSub_At '$@'))}
                                    )
                                  ]
                                  negated: T
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (C {(Lit_LBracket '[')} {(-s)} {(config.log)} 
                                          {(Lit_RBracket ']')}
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(echo)})
                                    (C {(echo)} 
                                      {
                                        (DQ 
                                          (
'!!! Please attach the following file when seeking support:'
                                          )
                                        )
                                      }
                                    )
                                    (C {(echo)} {(DQ ('!!! ') (${ VSub_Name PWD) (/config.log))})
                                  ]
                                )
                              ]
                            )
                            (C {(__helpers_die)} {(DQ ('econf failed'))})
                            (command.ControlFlow
                              token: <ControlFlow_Return return>
                              arg_word: {(1)}
                            )
                          ]
                        )
                      ]
                    )
                  ]
                )
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (C {(Lit_LBracket '[')} {(-f)} {(DQ (${ VSub_Name ECONF_SOURCE) (/configure))} 
                          {(Lit_RBracket ']')}
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [(C {(die)} {(DQ ('configure is not executable'))})]
                )
              ]
              else_action: [(C {(die)} {(DQ ('no configure script found'))})]
            )
          ]
        )
    )
    (command.ShFunction
      name: einstall
      body: 
        (command.BraceGroup
          children: [
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: (command.Pipeline children:[(C {(___eapi_has_einstall)})] negated:T)
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (C {(die)} 
                      {
                        (DQ ("'") (${ VSub_Name FUNCNAME) ("' has been banned for EAPI '") 
                          ($ VSub_DollarName '$EAPI') ("'")
                        )
                      }
                    )
                    (command.ControlFlow
                      token: <ControlFlow_Exit exit>
                      arg_word: {(1)}
                    )
                  ]
                )
              ]
            )
            (C {(local)} {(Lit_VarLike 'LOCAL_EXTRA_EINSTALL=') (DQ (${ VSub_Name EXTRA_EINSTALL))})
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.Pipeline
                          children: [(C {(___eapi_has_prefix_variables)})]
                          negated: T
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [(C {(local)} {(Lit_VarLike 'ED=') (${ VSub_Name D)})]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:LIBDIR_VAR)
                  op: Equal
                  rhs: {(DQ (LIBDIR_) (${ VSub_Name ABI))}
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (C {(Lit_LBracket '[')} {(-n)} {(DQ (${ VSub_Name ABI))} {(-a)} {(-n)} 
                          {(DQ (braced_var_sub token:<VSub_Name LIBDIR_VAR> prefix_op:VSub_Bang))} {(Lit_RBracket ']')}
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:CONF_LIBDIR)
                          op: Equal
                          rhs: {(DQ (braced_var_sub token:<VSub_Name LIBDIR_VAR> prefix_op:VSub_Bang))}
                        )
                      ]
                    )
                  ]
                )
              ]
            )
            (C {(unset)} {(LIBDIR_VAR)})
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.AndOr
                          ops: [Op_DAmp]
                          children: [
                            (C {(Lit_LBracket '[')} {(-n)} {(DQ (${ VSub_Name CONF_LIBDIR))} 
                              {(Lit_RBracket ']')}
                            )
                            (C {(Lit_LBracket '[')} 
                              {
                                (DQ 
                                  (braced_var_sub
                                    token: <VSub_Name CONF_PREFIX>
                                    suffix_op: (suffix_op.Unary op_id:VTest_ColonPlus arg_word:{(set)})
                                  )
                                )
                              } {(Lit_Equals '=')} {(KW_Set set)} {(Lit_RBracket ']')}
                            )
                          ]
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:EI_DESTLIBDIR)
                          op: Equal
                          rhs: 
                            {
                              (DQ (${ VSub_Name D) (/) (${ VSub_Name CONF_PREFIX) (/) 
                                (${ VSub_Name CONF_LIBDIR)
                              )
                            }
                        )
                      ]
                    )
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:EI_DESTLIBDIR)
                          op: Equal
                          rhs: 
                            {
                              (DQ 
                                (command_sub
                                  left_token: <Left_DollarParen '$('>
                                  command_list: 
                                    (command.CommandList
                                      children: [
                                        (C {(__strip_duplicate_slashes)} 
                                          {(DQ (${ VSub_Name EI_DESTLIBDIR))}
                                        )
                                      ]
                                    )
                                )
                              )
                            }
                        )
                      ]
                    )
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:LOCAL_EXTRA_EINSTALL)
                          op: Equal
                          rhs: 
                            {
                              (DQ ('libdir=') (${ VSub_Name EI_DESTLIBDIR) (' ') 
                                (${ VSub_Name LOCAL_EXTRA_EINSTALL)
                              )
                            }
                        )
                      ]
                    )
                    (C {(unset)} {(EI_DESTLIBDIR)})
                  ]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (C {(Lit_LBracket '[')} {(-f)} 
                          {(./) (Lit_LBracket '[') (mM) (Lit_RBracket ']') (akefile)} {(-o)} {(-f)} {(./GNUmakefile)} {(Lit_RBracket ']')}
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (C {(Lit_LBracket '[')} {(DQ (${ VSub_Name PORTAGE_DEBUG))} 
                                  {(Lit_Equals '=') (Lit_Equals '=')} {(DQ (1))} {(Lit_RBracket ']')}
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (C 
                              {
                                (braced_var_sub
                                  token: <VSub_Name MAKE>
                                  suffix_op: 
                                    (suffix_op.Unary
                                      op_id: VTest_ColonHyphen
                                      arg_word: {(make)}
                                    )
                                )
                              } {(-n)} {(Lit_VarLike 'prefix=') (DQ (${ VSub_Name ED) (usr))} 
                              {(Lit_VarLike 'datadir=') (DQ (${ VSub_Name ED) (usr/share))} {(Lit_VarLike 'infodir=') (DQ (${ VSub_Name ED) (usr/share/info))} 
                              {(Lit_VarLike 'localstatedir=') (DQ (${ VSub_Name ED) (var/lib))} {(Lit_VarLike 'mandir=') (DQ (${ VSub_Name ED) (usr/share/man))} 
                              {(Lit_VarLike 'sysconfdir=') (DQ (${ VSub_Name ED) (etc))} {(${ VSub_Name LOCAL_EXTRA_EINSTALL)} {(${ VSub_Name MAKEOPTS)} {(-j1)} {(DQ ($ VSub_At '$@'))} 
                              {(${ VSub_Name EXTRA_EMAKE)} {(install)}
                            )
                          ]
                        )
                      ]
                    )
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Pipeline
                              children: [
                                (C 
                                  {
                                    (braced_var_sub
                                      token: <VSub_Name MAKE>
                                      suffix_op: 
                                        (suffix_op.Unary
                                          op_id: VTest_ColonHyphen
                                          arg_word: {(make)}
                                        )
                                    )
                                  } {(Lit_VarLike 'prefix=') (DQ (${ VSub_Name ED) (usr))} 
                                  {(Lit_VarLike 'datadir=') (DQ (${ VSub_Name ED) (usr/share))} {(Lit_VarLike 'infodir=') (DQ (${ VSub_Name ED) (usr/share/info))} 
                                  {(Lit_VarLike 'localstatedir=') (DQ (${ VSub_Name ED) (var/lib))} {(Lit_VarLike 'mandir=') (DQ (${ VSub_Name ED) (usr/share/man))} 
                                  {(Lit_VarLike 'sysconfdir=') (DQ (${ VSub_Name ED) (etc))} {(${ VSub_Name LOCAL_EXTRA_EINSTALL)} {(${ VSub_Name MAKEOPTS)} {(-j1)} {(DQ ($ VSub_At '$@'))} 
                                  {(${ VSub_Name EXTRA_EMAKE)} {(install)}
                                )
                              ]
                              negated: T
                            )
                          ]
                          action: [
                            (C {(__helpers_die)} {(DQ ('einstall failed'))})
                            (command.ControlFlow
                              token: <ControlFlow_Return return>
                              arg_word: {(1)}
                            )
                          ]
                        )
                      ]
                    )
                  ]
                )
              ]
              else_action: [(C {(die)} {(DQ ('no Makefile found'))})]
            )
          ]
        )
    )
    (command.ShFunction
      name: __eapi0_pkg_nofetch
      body: 
        (command.BraceGroup
          children: [
            (command.AndOr
              ops: [Op_DAmp]
              children: [
                (command.DBracket
                  expr: (bool_expr.Unary op_id:BoolUnary_z child:{(${ VSub_Name A)})
                )
                (command.ControlFlow token:<ControlFlow_Return return>)
              ]
            )
            (C {(elog)} {(DQ ('The following files cannot be fetched for ') (${ VSub_Name PN) (':'))})
            (C {(local)} {(x)})
            (command.ForEach
              iter_name: x
              iter_words: [{(${ VSub_Name A)}]
              do_arg_iter: F
              body: (command.DoGroup children:[(C {(elog)} {(DQ ('   ') (${ VSub_Name x))})])
            )
          ]
        )
    )
    (command.ShFunction
      name: __eapi0_src_unpack
      body: 
        (command.BraceGroup
          children: [
            (command.AndOr
              ops: [Op_DAmp]
              children: [
                (command.DBracket
                  expr: (bool_expr.Unary op_id:BoolUnary_n child:{(${ VSub_Name A)})
                )
                (C {(unpack)} {(${ VSub_Name A)})
              ]
            )
          ]
        )
    )
    (command.ShFunction
      name: __eapi0_src_compile
      body: 
        (command.BraceGroup
          children: [
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: (C {(Lit_LBracket '[')} {(-x)} {(./configure)} {(Lit_RBracket ']')})
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [(C {(econf)})]
                )
              ]
            )
            (C {(__eapi2_src_compile)})
          ]
        )
    )
    (command.ShFunction
      name: __eapi0_src_test
      body: 
        (command.BraceGroup
          children: [
            (C {(local)} 
              {(Lit_VarLike 'emake_cmd=') 
                (DQ 
                  (braced_var_sub
                    token: <VSub_Name MAKE>
                    suffix_op: (suffix_op.Unary op_id:VTest_ColonHyphen arg_word:{(make)})
                  ) (' ') (${ VSub_Name MAKEOPTS) (' ') (${ VSub_Name EXTRA_EMAKE)
                )
              }
            )
            (C {(local)} {(Lit_VarLike 'internal_opts=')})
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: (C {(___eapi_default_src_test_disables_parallel_jobs)})
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:internal_opts)
                          op: PlusEqual
                          rhs: {(DQ (' -j1'))}
                        )
                      ]
                    )
                  ]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.Simple
                          words: [
                            {($ VSub_DollarName '$emake_cmd')}
                            {(${ VSub_Name internal_opts)}
                            {(check)}
                            {(-n)}
                          ]
                          redirects: [
                            (redir.Redir
                              op: <Redir_AndGreat '&>'>
                              fd: 16777215
                              arg_word: {(/dev/null)}
                            )
                          ]
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (command.Simple
                      words: [
                        {(__vecho)}
                        {(DQ (${ VSub_Name emake_cmd) (' ') (${ VSub_Name internal_opts) (' check'))}
                      ]
                      redirects: [(redir.Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(2)})]
                    )
                    (command.AndOr
                      ops: [Op_DPipe]
                      children: [
                        (C {($ VSub_DollarName '$emake_cmd')} {(${ VSub_Name internal_opts)} {(check)})
                        (C {(die)} {(DQ ('Make check failed. See above for details.'))})
                      ]
                    )
                  ]
                )
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.Simple
                          words: [
                            {($ VSub_DollarName '$emake_cmd')}
                            {(${ VSub_Name internal_opts)}
                            {(test)}
                            {(-n)}
                          ]
                          redirects: [
                            (redir.Redir
                              op: <Redir_AndGreat '&>'>
                              fd: 16777215
                              arg_word: {(/dev/null)}
                            )
                          ]
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (command.Simple
                      words: [
                        {(__vecho)}
                        {(DQ (${ VSub_Name emake_cmd) (' ') (${ VSub_Name internal_opts) (' test'))}
                      ]
                      redirects: [(redir.Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(2)})]
                    )
                    (command.AndOr
                      ops: [Op_DPipe]
                      children: [
                        (C {($ VSub_DollarName '$emake_cmd')} {(${ VSub_Name internal_opts)} {(test)})
                        (C {(die)} {(DQ ('Make test failed. See above for details.'))})
                      ]
                    )
                  ]
                )
              ]
            )
          ]
        )
    )
    (command.ShFunction
      name: __eapi1_src_compile
      body: (command.BraceGroup children:[(C {(__eapi2_src_configure)}) (C {(__eapi2_src_compile)})])
    )
    (command.ShFunction
      name: __eapi2_src_prepare
      body: (command.BraceGroup children:[(C {(Lit_Other ':')})])
    )
    (command.ShFunction
      name: __eapi2_src_configure
      body: 
        (command.BraceGroup
          children: [
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.DBracket
                          expr: 
                            (bool_expr.Unary
                              op_id: BoolUnary_x
                              child: 
                                {
                                  (braced_var_sub
                                    token: <VSub_Name ECONF_SOURCE>
                                    suffix_op: (suffix_op.Unary op_id:VTest_ColonHyphen arg_word:{(.)})
                                  ) (/configure)
                                }
                            )
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [(C {(econf)})]
                )
              ]
            )
          ]
        )
    )
    (command.ShFunction
      name: __eapi2_src_compile
      body: 
        (command.BraceGroup
          children: [
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.AndOr
                          ops: [Op_DPipe Op_DPipe]
                          children: [
                            (C {(Lit_LBracket '[')} {(-f)} {(Makefile)} {(Lit_RBracket ']')})
                            (C {(Lit_LBracket '[')} {(-f)} {(GNUmakefile)} {(Lit_RBracket ']')})
                            (C {(Lit_LBracket '[')} {(-f)} {(makefile)} {(Lit_RBracket ']')})
                          ]
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (command.AndOr
                      ops: [Op_DPipe]
                      children: [(C {(emake)}) (C {(die)} {(DQ ('emake failed'))})]
                    )
                  ]
                )
              ]
            )
          ]
        )
    )
    (command.ShFunction
      name: __eapi4_src_install
      body: 
        (command.BraceGroup
          children: [
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.DBracket
                          expr: 
                            (bool_expr.LogicalOr
                              left: (bool_expr.Unary op_id:BoolUnary_f child:{(Makefile)})
                              right: 
                                (bool_expr.LogicalOr
                                  left: (bool_expr.Unary op_id:BoolUnary_f child:{(GNUmakefile)})
                                  right: (bool_expr.Unary op_id:BoolUnary_f child:{(makefile)})
                                )
                            )
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [(C {(emake)} {(Lit_VarLike 'DESTDIR=') (DQ (${ VSub_Name D))} {(install)})]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.Pipeline
                          children: [
                            (command.Simple
                              words: [{(declare)} {(-p)} {(DOCS)}]
                              redirects: [
                                (redir.Redir
                                  op: <Redir_AndGreat '&>'>
                                  fd: 16777215
                                  arg_word: {(/dev/null)}
                                )
                              ]
                            )
                          ]
                          negated: T
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (C {(local)} {(d)})
                    (command.ForEach
                      iter_name: d
                      iter_words: [
                        {(README) (Lit_Star '*')}
                        {(ChangeLog)}
                        {(AUTHORS)}
                        {(NEWS)}
                        {(TODO)}
                        {(CHANGES)}
                        {(THANKS)}
                        {(BUGS)}
                        {(FAQ)}
                        {(CREDITS)}
                        {(CHANGELOG)}
                      ]
                      do_arg_iter: F
                      body: 
                        (command.DoGroup
                          children: [
                            (command.AndOr
                              ops: [Op_DAmp]
                              children: [
                                (command.DBracket
                                  expr: 
                                    (bool_expr.Unary
                                      op_id: BoolUnary_s
                                      child: {(DQ (${ VSub_Name d))}
                                    )
                                )
                                (C {(dodoc)} {(DQ (${ VSub_Name d))})
                              ]
                            )
                          ]
                        )
                    )
                  ]
                )
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.DBracket
                          expr: 
                            (bool_expr.Binary
                              op_id: BoolBinary_GlobDEqual
                              left: 
                                {
                                  (command_sub
                                    left_token: <Left_DollarParen '$('>
                                    command_list: 
                                      (command.CommandList
                                        children: [(C {(declare)} {(-p)} {(DOCS)})]
                                      )
                                  )
                                }
                              right: {(DQ ('declare -a ')) (Lit_Other '*')}
                            )
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (C {(dodoc)} 
                      {
                        (DQ 
                          (braced_var_sub
                            token: <VSub_Name DOCS>
                            bracket_op: (bracket_op.WholeArray op_id:Lit_At)
                          )
                        )
                      }
                    )
                  ]
                )
              ]
              else_action: [(C {(dodoc)} {(${ VSub_Name DOCS)})]
            )
          ]
        )
    )
    (command.ShFunction
      name: __eapi6_src_prepare
      body: 
        (command.BraceGroup
          children: [
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.DBracket
                          expr: 
                            (bool_expr.Binary
                              op_id: BoolBinary_GlobDEqual
                              left: 
                                {
                                  (command_sub
                                    left_token: <Left_DollarParen '$('>
                                    command_list: 
                                      (command.CommandList
                                        children: [
                                          (command.Simple
                                            words: [{(declare)} {(-p)} {(PATCHES)}]
                                            redirects: [
                                              (redir.Redir
                                                op: <Redir_Great '2>'>
                                                fd: 2
                                                arg_word: {(/dev/null)}
                                              )
                                            ]
                                          )
                                        ]
                                      )
                                  )
                                }
                              right: {(DQ ('declare -a')) (Lit_Other '*')}
                            )
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (command.AndOr
                      ops: [Op_DAmp]
                      children: [
                        (command.DBracket
                          expr: 
                            (bool_expr.Unary
                              op_id: BoolUnary_n
                              child: 
                                {
                                  (braced_var_sub
                                    token: <VSub_Name PATCHES>
                                    bracket_op: (bracket_op.WholeArray op_id:Lit_At)
                                  )
                                }
                            )
                        )
                        (C {(eapply)} 
                          {
                            (DQ 
                              (braced_var_sub
                                token: <VSub_Name PATCHES>
                                bracket_op: (bracket_op.WholeArray op_id:Lit_At)
                              )
                            )
                          }
                        )
                      ]
                    )
                  ]
                )
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.DBracket
                          expr: (bool_expr.Unary op_id:BoolUnary_n child:{(${ VSub_Name PATCHES)})
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [(C {(eapply)} {(${ VSub_Name PATCHES)})]
                )
              ]
            )
            (C {(eapply_user)})
          ]
        )
    )
    (command.ShFunction
      name: __eapi6_src_install
      body: 
        (command.BraceGroup
          children: [
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.DBracket
                          expr: 
                            (bool_expr.LogicalOr
                              left: (bool_expr.Unary op_id:BoolUnary_f child:{(Makefile)})
                              right: 
                                (bool_expr.LogicalOr
                                  left: (bool_expr.Unary op_id:BoolUnary_f child:{(GNUmakefile)})
                                  right: (bool_expr.Unary op_id:BoolUnary_f child:{(makefile)})
                                )
                            )
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [(C {(emake)} {(Lit_VarLike 'DESTDIR=') (DQ (${ VSub_Name D))} {(install)})]
                )
              ]
            )
            (C {(einstalldocs)})
          ]
        )
    )
    (command.ShFunction
      name: has_version
      body: 
        (command.BraceGroup
          children: [
            (C {(local)} {(atom)} {(eroot)} {(Lit_VarLike 'host_root=') (false)} 
              {(Lit_VarLike 'root=') (${ VSub_Name ROOT)}
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.DBracket
                          expr: 
                            (bool_expr.Binary
                              op_id: BoolBinary_GlobDEqual
                              left: {($ VSub_Number '$1')}
                              right: {(--host-root)}
                            )
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (command.ShAssignment
                      pairs: [(assign_pair lhs:(sh_lhs_expr.Name name:host_root) op:Equal rhs:{(true)})]
                    )
                    (C {(shift)})
                  ]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:atom)
                  op: Equal
                  rhs: {($ VSub_Number '$1')}
                )
              ]
            )
            (C {(shift)})
            (command.AndOr
              ops: [Op_DAmp]
              children: [
                (C {(Lit_LBracket '[')} {($ VSub_Pound '$#')} {(-gt)} {(0)} {(Lit_RBracket ']')})
                (C {(die)} 
                  {
                    (DQ 
                      (braced_var_sub
                        token: <VSub_Name FUNCNAME>
                        bracket_op: 
                          (bracket_op.ArrayIndex
                            expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                          )
                      ) (': unused argument(s): ') ($ VSub_Star '$*')
                    )
                  }
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: (C {(${ VSub_Name host_root)})
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.Pipeline
                                  children: [
                                    (C {(___eapi_best_version_and_has_version_support_--host-root)})
                                  ]
                                  negated: T
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (C {(die)} 
                              {
                                (DQ 
                                  (braced_var_sub
                                    token: <VSub_Name FUNCNAME>
                                    bracket_op: 
                                      (bracket_op.ArrayIndex
                                        expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                      )
                                  ) (': option --host-root is not supported with EAPI ') (${ VSub_Name EAPI)
                                )
                              }
                            )
                          ]
                        )
                      ]
                    )
                    (command.ShAssignment
                      pairs: [(assign_pair lhs:(sh_lhs_expr.Name name:root) op:Equal rhs:{(/)})]
                    )
                  ]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: (C {(___eapi_has_prefix_variables)})
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: (C {(${ VSub_Name host_root)})
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:eroot)
                                  op: Equal
                                  rhs: 
                                    {
                                      (braced_var_sub
                                        token: <VSub_Name root>
                                        suffix_op: 
                                          (suffix_op.Unary
                                            op_id: VOp1_Percent
                                            arg_word: {(Lit_Slash /)}
                                          )
                                      ) (${ VSub_Name PORTAGE_OVERRIDE_EPREFIX) (/)
                                    }
                                )
                              ]
                            )
                          ]
                        )
                      ]
                      else_action: [
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:eroot)
                              op: Equal
                              rhs: 
                                {
                                  (braced_var_sub
                                    token: <VSub_Name root>
                                    suffix_op: 
                                      (suffix_op.Unary
                                        op_id: VOp1_Percent
                                        arg_word: {(Lit_Slash /)}
                                      )
                                  ) (${ VSub_Name EPREFIX) (/)
                                }
                            )
                          ]
                        )
                      ]
                    )
                  ]
                )
              ]
              else_action: [
                (command.ShAssignment
                  pairs: [
                    (assign_pair
                      lhs: (sh_lhs_expr.Name name:eroot)
                      op: Equal
                      rhs: {(${ VSub_Name root)}
                    )
                  ]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.DBracket
                          expr: 
                            (bool_expr.Unary
                              op_id: BoolUnary_n
                              child: {($ VSub_DollarName '$PORTAGE_IPC_DAEMON')}
                            )
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (C {(DQ ($ VSub_DollarName '$PORTAGE_BIN_PATH')) (/ebuild-ipc)} {(has_version)} 
                      {(DQ (${ VSub_Name eroot))} {(DQ (${ VSub_Name atom))}
                    )
                  ]
                )
              ]
              else_action: [
                (C {(DQ (${ VSub_Name PORTAGE_BIN_PATH) (/ebuild-helpers/portageq))} {(has_version)} 
                  {(DQ (${ VSub_Name eroot))} {(DQ (${ VSub_Name atom))}
                )
              ]
            )
            (C {(local)} {(Lit_VarLike 'retval=') ($ VSub_QMark '$?')})
            (command.Case
              to_match: {(DQ (${ VSub_Name retval))}
              arms: [
                (case_arm
                  pat_list: [{(0)} {(1)}]
                  action: [
                    (command.ControlFlow
                      token: <ControlFlow_Return return>
                      arg_word: {(${ VSub_Name retval)}
                    )
                  ]
                )
                (case_arm
                  pat_list: [{(2)}]
                  action: [
                    (C {(die)} 
                      {
                        (DQ 
                          (braced_var_sub
                            token: <VSub_Name FUNCNAME>
                            bracket_op: 
                              (bracket_op.ArrayIndex
                                expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                              )
                          ) (': invalid atom: ') (${ VSub_Name atom)
                        )
                      }
                    )
                  ]
                )
                (case_arm
                  pat_list: [{(Lit_Star '*')}]
                  action: [
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.DBracket
                                  expr: 
                                    (bool_expr.Unary
                                      op_id: BoolUnary_n
                                      child: {(${ VSub_Name PORTAGE_IPC_DAEMON)}
                                    )
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (C {(die)} 
                              {
                                (DQ 
                                  (braced_var_sub
                                    token: <VSub_Name FUNCNAME>
                                    bracket_op: 
                                      (bracket_op.ArrayIndex
                                        expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                      )
                                  ) (': unexpected ebuild-ipc exit code: ') (${ VSub_Name retval)
                                )
                              }
                            )
                          ]
                        )
                      ]
                      else_action: [
                        (C {(die)} 
                          {
                            (DQ 
                              (braced_var_sub
                                token: <VSub_Name FUNCNAME>
                                bracket_op: 
                                  (bracket_op.ArrayIndex
                                    expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                  )
                              ) (': unexpected portageq exit code: ') (${ VSub_Name retval)
                            )
                          }
                        )
                      ]
                    )
                  ]
                )
              ]
            )
          ]
        )
    )
    (command.ShFunction
      name: best_version
      body: 
        (command.BraceGroup
          children: [
            (C {(local)} {(atom)} {(eroot)} {(Lit_VarLike 'host_root=') (false)} 
              {(Lit_VarLike 'root=') (${ VSub_Name ROOT)}
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.DBracket
                          expr: 
                            (bool_expr.Binary
                              op_id: BoolBinary_GlobDEqual
                              left: {($ VSub_Number '$1')}
                              right: {(--host-root)}
                            )
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (command.ShAssignment
                      pairs: [(assign_pair lhs:(sh_lhs_expr.Name name:host_root) op:Equal rhs:{(true)})]
                    )
                    (C {(shift)})
                  ]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:atom)
                  op: Equal
                  rhs: {($ VSub_Number '$1')}
                )
              ]
            )
            (C {(shift)})
            (command.AndOr
              ops: [Op_DAmp]
              children: [
                (C {(Lit_LBracket '[')} {($ VSub_Pound '$#')} {(-gt)} {(0)} {(Lit_RBracket ']')})
                (C {(die)} 
                  {
                    (DQ 
                      (braced_var_sub
                        token: <VSub_Name FUNCNAME>
                        bracket_op: 
                          (bracket_op.ArrayIndex
                            expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                          )
                      ) (': unused argument(s): ') ($ VSub_Star '$*')
                    )
                  }
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: (C {(${ VSub_Name host_root)})
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.Pipeline
                                  children: [
                                    (C {(___eapi_best_version_and_has_version_support_--host-root)})
                                  ]
                                  negated: T
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (C {(die)} 
                              {
                                (DQ 
                                  (braced_var_sub
                                    token: <VSub_Name FUNCNAME>
                                    bracket_op: 
                                      (bracket_op.ArrayIndex
                                        expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                      )
                                  ) (': option --host-root is not supported with EAPI ') (${ VSub_Name EAPI)
                                )
                              }
                            )
                          ]
                        )
                      ]
                    )
                    (command.ShAssignment
                      pairs: [(assign_pair lhs:(sh_lhs_expr.Name name:root) op:Equal rhs:{(/)})]
                    )
                  ]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: (C {(___eapi_has_prefix_variables)})
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: (C {(${ VSub_Name host_root)})
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:eroot)
                                  op: Equal
                                  rhs: 
                                    {
                                      (braced_var_sub
                                        token: <VSub_Name root>
                                        suffix_op: 
                                          (suffix_op.Unary
                                            op_id: VOp1_Percent
                                            arg_word: {(Lit_Slash /)}
                                          )
                                      ) (${ VSub_Name PORTAGE_OVERRIDE_EPREFIX) (/)
                                    }
                                )
                              ]
                            )
                          ]
                        )
                      ]
                      else_action: [
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:eroot)
                              op: Equal
                              rhs: 
                                {
                                  (braced_var_sub
                                    token: <VSub_Name root>
                                    suffix_op: 
                                      (suffix_op.Unary
                                        op_id: VOp1_Percent
                                        arg_word: {(Lit_Slash /)}
                                      )
                                  ) (${ VSub_Name EPREFIX) (/)
                                }
                            )
                          ]
                        )
                      ]
                    )
                  ]
                )
              ]
              else_action: [
                (command.ShAssignment
                  pairs: [
                    (assign_pair
                      lhs: (sh_lhs_expr.Name name:eroot)
                      op: Equal
                      rhs: {(${ VSub_Name root)}
                    )
                  ]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.DBracket
                          expr: 
                            (bool_expr.Unary
                              op_id: BoolUnary_n
                              child: {($ VSub_DollarName '$PORTAGE_IPC_DAEMON')}
                            )
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [
                    (C {(DQ ($ VSub_DollarName '$PORTAGE_BIN_PATH')) (/ebuild-ipc)} {(best_version)} 
                      {(DQ (${ VSub_Name eroot))} {(DQ (${ VSub_Name atom))}
                    )
                  ]
                )
              ]
              else_action: [
                (C {(DQ (${ VSub_Name PORTAGE_BIN_PATH) (/ebuild-helpers/portageq))} {(best_version)} 
                  {(DQ (${ VSub_Name eroot))} {(DQ (${ VSub_Name atom))}
                )
              ]
            )
            (C {(local)} {(Lit_VarLike 'retval=') ($ VSub_QMark '$?')})
            (command.Case
              to_match: {(DQ (${ VSub_Name retval))}
              arms: [
                (case_arm
                  pat_list: [{(0)} {(1)}]
                  action: [
                    (command.ControlFlow
                      token: <ControlFlow_Return return>
                      arg_word: {(${ VSub_Name retval)}
                    )
                  ]
                )
                (case_arm
                  pat_list: [{(2)}]
                  action: [
                    (C {(die)} 
                      {
                        (DQ 
                          (braced_var_sub
                            token: <VSub_Name FUNCNAME>
                            bracket_op: 
                              (bracket_op.ArrayIndex
                                expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                              )
                          ) (': invalid atom: ') (${ VSub_Name atom)
                        )
                      }
                    )
                  ]
                )
                (case_arm
                  pat_list: [{(Lit_Star '*')}]
                  action: [
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.DBracket
                                  expr: 
                                    (bool_expr.Unary
                                      op_id: BoolUnary_n
                                      child: {(${ VSub_Name PORTAGE_IPC_DAEMON)}
                                    )
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (C {(die)} 
                              {
                                (DQ 
                                  (braced_var_sub
                                    token: <VSub_Name FUNCNAME>
                                    bracket_op: 
                                      (bracket_op.ArrayIndex
                                        expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                      )
                                  ) (': unexpected ebuild-ipc exit code: ') (${ VSub_Name retval)
                                )
                              }
                            )
                          ]
                        )
                      ]
                      else_action: [
                        (C {(die)} 
                          {
                            (DQ 
                              (braced_var_sub
                                token: <VSub_Name FUNCNAME>
                                bracket_op: 
                                  (bracket_op.ArrayIndex
                                    expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                  )
                              ) (': unexpected portageq exit code: ') (${ VSub_Name retval)
                            )
                          }
                        )
                      ]
                    )
                  ]
                )
              ]
            )
          ]
        )
    )
    (command.If
      arms: [
        (if_arm
          cond: [(command.Sentence child:(C {(___eapi_has_get_libdir)}) terminator:<Op_Semi ';'>)]
          action: [
            (command.ShFunction
              name: get_libdir
              body: 
                (command.BraceGroup
                  children: [
                    (C {(local)} {(Lit_VarLike 'libdir_var=') (DQ (LIBDIR_) (${ VSub_Name ABI))})
                    (C {(local)} {(Lit_VarLike 'libdir=') (DQ (lib))})
                    (command.AndOr
                      ops: [Op_DAmp]
                      children: [
                        (command.DBracket
                          expr: 
                            (bool_expr.LogicalAnd
                              left: (bool_expr.Unary op_id:BoolUnary_n child:{(${ VSub_Name ABI)})
                              right: 
                                (bool_expr.Unary
                                  op_id: BoolUnary_n
                                  child: 
                                    {
                                      (braced_var_sub
                                        token: <VSub_Name libdir_var>
                                        prefix_op: VSub_Bang
                                      )
                                    }
                                )
                            )
                        )
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:libdir)
                              op: Equal
                              rhs: {(braced_var_sub token:<VSub_Name libdir_var> prefix_op:VSub_Bang)}
                            )
                          ]
                        )
                      ]
                    )
                    (C {(echo)} {(DQ (${ VSub_Name libdir))})
                  ]
                )
            )
          ]
        )
      ]
    )
    (command.If
      arms: [
        (if_arm
          cond: [(command.Sentence child:(C {(___eapi_has_einstalldocs)}) terminator:<Op_Semi ';'>)]
          action: [
            (command.ShFunction
              name: einstalldocs
              body: 
                (command.BraceGroup
                  children: [
                    (command.Subshell
                      command_list: 
                        (command.CommandList
                          children: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.Pipeline
                                          children: [
                                            (command.Simple
                                              words: [{(declare)} {(-p)} {(DOCS)}]
                                              redirects: [
                                                (redir.Redir
                                                  op: <Redir_AndGreat '&>'>
                                                  fd: 16777215
                                                  arg_word: {(/dev/null)}
                                                )
                                              ]
                                            )
                                          ]
                                          negated: T
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(local)} {(d)})
                                    (command.ForEach
                                      iter_name: d
                                      iter_words: [
                                        {(README) (Lit_Star '*')}
                                        {(ChangeLog)}
                                        {(AUTHORS)}
                                        {(NEWS)}
                                        {(TODO)}
                                        {(CHANGES)}
                                        {(THANKS)}
                                        {(BUGS)}
                                        {(FAQ)}
                                        {(CREDITS)}
                                        {(CHANGELOG)}
                                      ]
                                      do_arg_iter: F
                                      body: 
                                        (command.DoGroup
                                          children: [
                                            (command.AndOr
                                              ops: [Op_DAmp Op_DAmp]
                                              children: [
                                                (command.DBracket
                                                  expr: 
                                                    (bool_expr.LogicalAnd
                                                      left: 
                                                        (bool_expr.Unary
                                                          op_id: BoolUnary_f
                                                          child: {(${ VSub_Name d)}
                                                        )
                                                      right: 
                                                        (bool_expr.Unary
                                                          op_id: BoolUnary_s
                                                          child: {(${ VSub_Name d)}
                                                        )
                                                    )
                                                )
                                                (C {(docinto)} {(/)})
                                                (C {(dodoc)} {(DQ (${ VSub_Name d))})
                                              ]
                                            )
                                          ]
                                        )
                                    )
                                  ]
                                )
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.DBracket
                                          expr: 
                                            (bool_expr.Binary
                                              op_id: BoolBinary_GlobDEqual
                                              left: 
                                                {
                                                  (command_sub
                                                    left_token: <Left_DollarParen '$('>
                                                    command_list: 
                                                      (command.CommandList
                                                        children: [(C {(declare)} {(-p)} {(DOCS)})]
                                                      )
                                                  )
                                                }
                                              right: {(DQ ('declare -a')) (Lit_Other '*')}
                                            )
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (command.AndOr
                                      ops: [Op_DAmp Op_DAmp]
                                      children: [
                                        (command.DBracket
                                          expr: 
                                            (bool_expr.WordTest
                                              w: 
                                                {
                                                  (braced_var_sub
                                                    token: <VSub_Name DOCS>
                                                    bracket_op: (bracket_op.WholeArray op_id:Lit_At)
                                                  )
                                                }
                                            )
                                        )
                                        (C {(docinto)} {(/)})
                                        (C {(dodoc)} {(-r)} 
                                          {
                                            (DQ 
                                              (braced_var_sub
                                                token: <VSub_Name DOCS>
                                                bracket_op: (bracket_op.WholeArray op_id:Lit_At)
                                              )
                                            )
                                          }
                                        )
                                      ]
                                    )
                                  ]
                                )
                              ]
                              else_action: [
                                (command.AndOr
                                  ops: [Op_DAmp Op_DAmp]
                                  children: [
                                    (command.DBracket
                                      expr: (bool_expr.WordTest w:{(${ VSub_Name DOCS)})
                                    )
                                    (C {(docinto)} {(/)})
                                    (C {(dodoc)} {(-r)} {(${ VSub_Name DOCS)})
                                  ]
                                )
                              ]
                            )
                          ]
                        )
                    )
                    (command.Subshell
                      command_list: 
                        (command.CommandList
                          children: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.DBracket
                                          expr: 
                                            (bool_expr.Binary
                                              op_id: BoolBinary_GlobDEqual
                                              left: 
                                                {
                                                  (command_sub
                                                    left_token: <Left_DollarParen '$('>
                                                    command_list: 
                                                      (command.CommandList
                                                        children: [
                                                          (command.Simple
                                                            words: [{(declare)} {(-p)} {(HTML_DOCS)}]
                                                            redirects: [
                                                              (redir.Redir
                                                                op: <Redir_Great '2>'>
                                                                fd: 2
                                                                arg_word: {(/dev/null)}
                                                              )
                                                            ]
                                                          )
                                                        ]
                                                      )
                                                  )
                                                }
                                              right: {(DQ ('declare -a')) (Lit_Other '*')}
                                            )
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (command.AndOr
                                      ops: [Op_DAmp Op_DAmp]
                                      children: [
                                        (command.DBracket
                                          expr: 
                                            (bool_expr.WordTest
                                              w: 
                                                {
                                                  (braced_var_sub
                                                    token: <VSub_Name HTML_DOCS>
                                                    bracket_op: (bracket_op.WholeArray op_id:Lit_At)
                                                  )
                                                }
                                            )
                                        )
                                        (C {(docinto)} {(html)})
                                        (C {(dodoc)} {(-r)} 
                                          {
                                            (DQ 
                                              (braced_var_sub
                                                token: <VSub_Name HTML_DOCS>
                                                bracket_op: (bracket_op.WholeArray op_id:Lit_At)
                                              )
                                            )
                                          }
                                        )
                                      ]
                                    )
                                  ]
                                )
                              ]
                              else_action: [
                                (command.AndOr
                                  ops: [Op_DAmp Op_DAmp]
                                  children: [
                                    (command.DBracket
                                      expr: (bool_expr.WordTest w:{(${ VSub_Name HTML_DOCS)})
                                    )
                                    (C {(docinto)} {(html)})
                                    (C {(dodoc)} {(-r)} {(${ VSub_Name HTML_DOCS)})
                                  ]
                                )
                              ]
                            )
                          ]
                        )
                    )
                  ]
                )
            )
          ]
        )
      ]
    )
    (command.If
      arms: [
        (if_arm
          cond: [(command.Sentence child:(C {(___eapi_has_eapply)}) terminator:<Op_Semi ';'>)]
          action: [
            (command.ShFunction
              name: eapply
              body: 
                (command.BraceGroup
                  children: [
                    (C {(local)} {(failed)} {(Lit_VarLike 'patch_cmd=') (patch)})
                    (C {(local)} {(-x)} {(Lit_VarLike 'LC_COLLATE=') (POSIX)})
                    (command.AndOr
                      ops: [Op_DAmp]
                      children: [
                        (command.Simple
                          words: [{(type)} {(-P)} {(gpatch)}]
                          redirects: [
                            (redir.Redir
                              op: <Redir_Great '>'>
                              fd: 16777215
                              arg_word: {(/dev/null)}
                            )
                          ]
                        )
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:patch_cmd)
                              op: Equal
                              rhs: {(gpatch)}
                            )
                          ]
                        )
                      ]
                    )
                    (command.ShFunction
                      name: _eapply_patch
                      body: 
                        (command.BraceGroup
                          children: [
                            (C {(local)} {(Lit_VarLike 'f=') (${ VSub_Number 1)})
                            (C {(local)} {(Lit_VarLike 'prefix=') (${ VSub_Number 2)})
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:started_applying)
                                  op: Equal
                                  rhs: {(1)}
                                )
                              ]
                            )
                            (C {(ebegin)} 
                              {
                                (DQ 
                                  (braced_var_sub
                                    token: <VSub_Name prefix>
                                    suffix_op: 
                                      (suffix_op.Unary
                                        op_id: VTest_ColonHyphen
                                        arg_word: {('Applying ')}
                                      )
                                  ) 
                                  (braced_var_sub
                                    token: <VSub_Name f>
                                    suffix_op: 
                                      (suffix_op.Unary
                                        op_id: VOp1_DPound
                                        arg_word: {('*') (Lit_Slash /)}
                                      )
                                  )
                                )
                              }
                            )
                            (command.Simple
                              words: [
                                {(${ VSub_Name patch_cmd)}
                                {(-p1)}
                                {(-f)}
                                {(-s)}
                                {(-g0)}
                                {(--no-backup-if-mismatch)}
                                {
                                  (DQ 
                                    (braced_var_sub
                                      token: <VSub_Name patch_options>
                                      bracket_op: (bracket_op.WholeArray op_id:Lit_At)
                                    )
                                  )
                                }
                              ]
                              redirects: [
                                (redir.Redir
                                  op: <Redir_Less '<'>
                                  fd: 16777215
                                  arg_word: {(DQ (${ VSub_Name f))}
                                )
                              ]
                            )
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:failed)
                                  op: Equal
                                  rhs: {(${ VSub_QMark '?')}
                                )
                              ]
                            )
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.Pipeline
                                          children: [(C {(eend)} {(DQ (${ VSub_Name failed))})]
                                          negated: T
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(__helpers_die)} 
                                      {
                                        (DQ ('patch -p1 ') 
                                          (braced_var_sub
                                            token: <VSub_Name patch_options>
                                            bracket_op: (bracket_op.WholeArray op_id:Arith_Star)
                                          ) (' failed with ') (${ VSub_Name f)
                                        )
                                      }
                                    )
                                  ]
                                )
                              ]
                            )
                          ]
                        )
                    )
                    (C {(local)} 
                      {(Lit_VarLike 'patch_options=') (sh_array_literal left:<Op_LParen '('>)} {(Lit_VarLike 'files=') (sh_array_literal left:<Op_LParen '('>)}
                    )
                    (C {(local)} {(i)} {(found_doublehyphen)})
                    (command.ForExpr
                      init: 
                        (arith_expr.BinaryAssign
                          op_id: Arith_Equal
                          left: (sh_lhs_expr.Name name:i)
                          right: (arith_expr.ArithWord w:{(Lit_Digits 1)})
                        )
                      cond: 
                        (arith_expr.Binary
                          op_id: Arith_LessEqual
                          left: (arith_expr.VarRef token:<Lit_ArithVarLike i>)
                          right: 
                            (arith_expr.ArithWord
                              w: {(braced_var_sub token:<VSub_At '@'> prefix_op:VSub_Pound)}
                            )
                        )
                      update: 
                        (arith_expr.UnaryAssign
                          op_id: Arith_DPlus
                          child: (sh_lhs_expr.Name name:i)
                        )
                      body: 
                        (command.DoGroup
                          children: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.DBracket
                                          expr: 
                                            (bool_expr.Binary
                                              op_id: BoolBinary_GlobDEqual
                                              left: 
                                                {
                                                  (braced_var_sub
                                                    token: <VSub_At '@'>
                                                    suffix_op: 
                                                      (suffix_op.Slice
                                                        begin: 
                                                          (arith_expr.VarRef
                                                            token: <Lit_ArithVarLike i>
                                                          )
                                                        length: 
                                                          (arith_expr.ArithWord
                                                            w: {(Lit_Digits 1)}
                                                          )
                                                      )
                                                  )
                                                }
                                              right: {(--)}
                                            )
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (command.ShAssignment
                                      pairs: [
                                        (assign_pair
                                          lhs: (sh_lhs_expr.Name name:patch_options)
                                          op: Equal
                                          rhs: 
                                            {
                                              (sh_array_literal
                                                left: <Op_LParen '('>
                                                words: [
                                                  {
                                                    (DQ 
                                                      (braced_var_sub
                                                        token: <VSub_At '@'>
                                                        suffix_op: 
                                                          (suffix_op.Slice
                                                            begin: 
                                                              (arith_expr.ArithWord
                                                                w: {(Lit_Digits 1)}
                                                              )
                                                            length: 
                                                              (arith_expr.Binary
                                                                op_id: Arith_Minus
                                                                left: 
                                                                  (arith_expr.VarRef
                                                                    token: <Lit_ArithVarLike i>
                                                                  )
                                                                right: 
                                                                  (arith_expr.ArithWord
                                                                    w: {(Lit_Digits 1)}
                                                                  )
                                                              )
                                                          )
                                                      )
                                                    )
                                                  }
                                                ]
                                              )
                                            }
                                        )
                                      ]
                                    )
                                    (command.ShAssignment
                                      pairs: [
                                        (assign_pair
                                          lhs: (sh_lhs_expr.Name name:files)
                                          op: Equal
                                          rhs: 
                                            {
                                              (sh_array_literal
                                                left: <Op_LParen '('>
                                                words: [
                                                  {
                                                    (DQ 
                                                      (braced_var_sub
                                                        token: <VSub_At '@'>
                                                        suffix_op: 
                                                          (suffix_op.Slice
                                                            begin: 
                                                              (arith_expr.Binary
                                                                op_id: Arith_Plus
                                                                left: 
                                                                  (arith_expr.VarRef
                                                                    token: <Lit_ArithVarLike i>
                                                                  )
                                                                right: 
                                                                  (arith_expr.ArithWord
                                                                    w: {(Lit_Digits 1)}
                                                                  )
                                                              )
                                                          )
                                                      )
                                                    )
                                                  }
                                                ]
                                              )
                                            }
                                        )
                                      ]
                                    )
                                    (command.ShAssignment
                                      pairs: [
                                        (assign_pair
                                          lhs: (sh_lhs_expr.Name name:found_doublehyphen)
                                          op: Equal
                                          rhs: {(1)}
                                        )
                                      ]
                                    )
                                    (command.ControlFlow
                                      token: <ControlFlow_Break break>
                                    )
                                  ]
                                )
                              ]
                            )
                          ]
                        )
                    )
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.DBracket
                                  expr: 
                                    (bool_expr.Unary
                                      op_id: BoolUnary_z
                                      child: {(${ VSub_Name found_doublehyphen)}
                                    )
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (command.ForExpr
                              init: 
                                (arith_expr.BinaryAssign
                                  op_id: Arith_Equal
                                  left: (sh_lhs_expr.Name name:i)
                                  right: (arith_expr.ArithWord w:{(Lit_Digits 1)})
                                )
                              cond: 
                                (arith_expr.Binary
                                  op_id: Arith_LessEqual
                                  left: (arith_expr.VarRef token:<Lit_ArithVarLike i>)
                                  right: 
                                    (arith_expr.ArithWord
                                      w: {(braced_var_sub token:<VSub_At '@'> prefix_op:VSub_Pound)}
                                    )
                                )
                              update: 
                                (arith_expr.UnaryAssign
                                  op_id: Arith_DPlus
                                  child: (sh_lhs_expr.Name name:i)
                                )
                              body: 
                                (command.DoGroup
                                  children: [
                                    (command.If
                                      arms: [
                                        (if_arm
                                          cond: [
                                            (command.Sentence
                                              child: 
                                                (command.DBracket
                                                  expr: 
                                                    (bool_expr.Binary
                                                      op_id: BoolBinary_GlobNEqual
                                                      left: 
                                                        {
                                                          (braced_var_sub
                                                            token: <VSub_At '@'>
                                                            suffix_op: 
                                                              (suffix_op.Slice
                                                                begin: 
                                                                  (arith_expr.VarRef
                                                                    token: <Lit_ArithVarLike i>
                                                                  )
                                                                length: 
                                                                  (arith_expr.ArithWord
                                                                    w: {(Lit_Digits 1)}
                                                                  )
                                                              )
                                                          )
                                                        }
                                                      right: {(-) (Lit_Other '*')}
                                                    )
                                                )
                                              terminator: <Op_Semi ';'>
                                            )
                                          ]
                                          action: [
                                            (command.ShAssignment
                                              pairs: [
                                                (assign_pair
                                                  lhs: (sh_lhs_expr.Name name:patch_options)
                                                  op: Equal
                                                  rhs: 
                                                    {
                                                      (sh_array_literal
                                                        left: <Op_LParen '('>
                                                        words: [
                                                          {
                                                            (DQ 
                                                              (braced_var_sub
                                                                token: <VSub_At '@'>
                                                                suffix_op: 
                                                                  (suffix_op.Slice
                                                                    begin: 
                                                                      (arith_expr.ArithWord
                                                                        w: {(Lit_Digits 1)}
                                                                      )
                                                                    length: 
                                                                      (arith_expr.Binary
                                                                        op_id: Arith_Minus
                                                                        left: 
                                                                          (arith_expr.VarRef
                                                                            token: 
                                                                              <Lit_ArithVarLike i>
                                                                          )
                                                                        right: 
                                                                          (arith_expr.ArithWord
                                                                            w: {(Lit_Digits 1)}
                                                                          )
                                                                      )
                                                                  )
                                                              )
                                                            )
                                                          }
                                                        ]
                                                      )
                                                    }
                                                )
                                              ]
                                            )
                                            (command.ShAssignment
                                              pairs: [
                                                (assign_pair
                                                  lhs: (sh_lhs_expr.Name name:files)
                                                  op: Equal
                                                  rhs: 
                                                    {
                                                      (sh_array_literal
                                                        left: <Op_LParen '('>
                                                        words: [
                                                          {
                                                            (DQ 
                                                              (braced_var_sub
                                                                token: <VSub_At '@'>
                                                                suffix_op: 
                                                                  (suffix_op.Slice
                                                                    begin: 
                                                                      (arith_expr.VarRef
                                                                        token: <Lit_ArithVarLike i>
                                                                      )
                                                                  )
                                                              )
                                                            )
                                                          }
                                                        ]
                                                      )
                                                    }
                                                )
                                              ]
                                            )
                                            (command.ControlFlow
                                              token: <ControlFlow_Break break>
                                            )
                                          ]
                                        )
                                      ]
                                    )
                                  ]
                                )
                            )
                            (command.ForEach
                              iter_name: i
                              iter_words: [
                                {
                                  (DQ 
                                    (braced_var_sub
                                      token: <VSub_Name files>
                                      bracket_op: (bracket_op.WholeArray op_id:Lit_At)
                                    )
                                  )
                                }
                              ]
                              do_arg_iter: F
                              body: 
                                (command.DoGroup
                                  children: [
                                    (command.If
                                      arms: [
                                        (if_arm
                                          cond: [
                                            (command.Sentence
                                              child: 
                                                (command.DBracket
                                                  expr: 
                                                    (bool_expr.Binary
                                                      op_id: BoolBinary_GlobDEqual
                                                      left: {(${ VSub_Name i)}
                                                      right: {(-) (Lit_Other '*')}
                                                    )
                                                )
                                              terminator: <Op_Semi ';'>
                                            )
                                          ]
                                          action: [
                                            (C {(die)} 
                                              {
                                                (DQ 
                                                  (
'eapply: all options must be passed before non-options'
                                                  )
                                                )
                                              }
                                            )
                                          ]
                                        )
                                      ]
                                    )
                                  ]
                                )
                            )
                          ]
                        )
                      ]
                    )
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.DBracket
                                  expr: 
                                    (bool_expr.Unary
                                      op_id: BoolUnary_z
                                      child: 
                                        {
                                          (braced_var_sub
                                            token: <VSub_Name files>
                                            bracket_op: (bracket_op.WholeArray op_id:Lit_At)
                                          )
                                        }
                                    )
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [(C {(die)} {(DQ ('eapply: no files specified'))})]
                        )
                      ]
                    )
                    (C {(local)} {(f)})
                    (command.ForEach
                      iter_name: f
                      iter_words: [
                        {
                          (DQ 
                            (braced_var_sub
                              token: <VSub_Name files>
                              bracket_op: (bracket_op.WholeArray op_id:Lit_At)
                            )
                          )
                        }
                      ]
                      do_arg_iter: F
                      body: 
                        (command.DoGroup
                          children: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.DBracket
                                          expr: 
                                            (bool_expr.Unary
                                              op_id: BoolUnary_d
                                              child: {(${ VSub_Name f)}
                                            )
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (command.ShFunction
                                      name: _eapply_get_files
                                      body: 
                                        (command.BraceGroup
                                          children: [
                                            (C {(local)} {(Lit_VarLike 'LC_ALL=') (POSIX)})
                                            (C {(local)} 
                                              {(Lit_VarLike 'prev_shopt=') 
                                                (command_sub
                                                  left_token: <Left_DollarParen '$('>
                                                  command_list: 
                                                    (command.CommandList
                                                      children: [(C {(shopt)} {(-p)} {(nullglob)})]
                                                    )
                                                )
                                              }
                                            )
                                            (C {(shopt)} {(-s)} {(nullglob)})
                                            (C {(local)} {(f)})
                                            (command.ForEach
                                              iter_name: f
                                              iter_words: [
                                                {(DQ (${ VSub_Number 1)) (/) (Lit_Star '*')}
                                              ]
                                              do_arg_iter: F
                                              body: 
                                                (command.DoGroup
                                                  children: [
                                                    (command.If
                                                      arms: [
                                                        (if_arm
                                                          cond: [
                                                            (command.Sentence
                                                              child: 
                                                                (command.DBracket
                                                                  expr: 
                                                                    (bool_expr.LogicalOr
                                                                      left: 
                                                                        (bool_expr.Binary
                                                                          op_id: 
BoolBinary_GlobDEqual
                                                                          left: {(${ VSub_Name f)}
                                                                          right: 
                                                                            {(Lit_Other '*') (.diff)}
                                                                        )
                                                                      right: 
                                                                        (bool_expr.Binary
                                                                          op_id: 
BoolBinary_GlobDEqual
                                                                          left: {(${ VSub_Name f)}
                                                                          right: 
                                                                            {(Lit_Other '*') (.patch)}
                                                                        )
                                                                    )
                                                                )
                                                              terminator: <Op_Semi ';'>
                                                            )
                                                          ]
                                                          action: [
                                                            (command.ShAssignment
                                                              pairs: [
                                                                (assign_pair
                                                                  lhs: (sh_lhs_expr.Name name:files)
                                                                  op: PlusEqual
                                                                  rhs: 
                                                                    {
                                                                      (sh_array_literal
                                                                        left: <Op_LParen '('>
                                                                        words: [{(DQ (${ VSub_Name f))}]
                                                                      )
                                                                    }
                                                                )
                                                              ]
                                                            )
                                                          ]
                                                        )
                                                      ]
                                                    )
                                                  ]
                                                )
                                            )
                                            (C {(${ VSub_Name prev_shopt)})
                                          ]
                                        )
                                    )
                                    (C {(local)} 
                                      {(Lit_VarLike 'files=') (sh_array_literal left:<Op_LParen '('>)}
                                    )
                                    (C {(_eapply_get_files)} {(DQ (${ VSub_Name f))})
                                    (command.AndOr
                                      ops: [Op_DAmp]
                                      children: [
                                        (command.DBracket
                                          expr: 
                                            (bool_expr.Unary
                                              op_id: BoolUnary_z
                                              child: 
                                                {
                                                  (braced_var_sub
                                                    token: <VSub_Name files>
                                                    bracket_op: (bracket_op.WholeArray op_id:Lit_At)
                                                  )
                                                }
                                            )
                                        )
                                        (C {(die)} 
                                          {
                                            (DQ ('No *.{patch,diff} files in directory ') 
                                              (${ VSub_Name f)
                                            )
                                          }
                                        )
                                      ]
                                    )
                                    (C {(einfo)} 
                                      {(DQ ('Applying patches from ') (${ VSub_Name f) (' ...'))}
                                    )
                                    (C {(local)} {(f2)})
                                    (command.ForEach
                                      iter_name: f2
                                      iter_words: [
                                        {
                                          (DQ 
                                            (braced_var_sub
                                              token: <VSub_Name files>
                                              bracket_op: (bracket_op.WholeArray op_id:Lit_At)
                                            )
                                          )
                                        }
                                      ]
                                      do_arg_iter: F
                                      body: 
                                        (command.DoGroup
                                          children: [
                                            (C {(_eapply_patch)} {(DQ (${ VSub_Name f2))} {(SQ <'  '>)})
                                            (command.AndOr
                                              ops: [Op_DAmp]
                                              children: [
                                                (command.DBracket
                                                  expr: 
                                                    (bool_expr.Binary
                                                      op_id: BoolBinary_ne
                                                      left: {(${ VSub_Name failed)}
                                                      right: {(0)}
                                                    )
                                                )
                                                (command.ControlFlow
                                                  token: <ControlFlow_Return return>
                                                  arg_word: {(DQ (${ VSub_Name failed))}
                                                )
                                              ]
                                            )
                                          ]
                                        )
                                    )
                                  ]
                                )
                              ]
                              else_action: [
                                (C {(_eapply_patch)} {(DQ (${ VSub_Name f))})
                                (command.AndOr
                                  ops: [Op_DAmp]
                                  children: [
                                    (command.DBracket
                                      expr: 
                                        (bool_expr.Binary
                                          op_id: BoolBinary_ne
                                          left: {(${ VSub_Name failed)}
                                          right: {(0)}
                                        )
                                    )
                                    (command.ControlFlow
                                      token: <ControlFlow_Return return>
                                      arg_word: {(DQ (${ VSub_Name failed))}
                                    )
                                  ]
                                )
                              ]
                            )
                          ]
                        )
                    )
                    (command.ControlFlow
                      token: <ControlFlow_Return return>
                      arg_word: {(0)}
                    )
                  ]
                )
            )
          ]
        )
      ]
    )
    (command.If
      arms: [
        (if_arm
          cond: [(command.Sentence child:(C {(___eapi_has_eapply_user)}) terminator:<Op_Semi ';'>)]
          action: [
            (command.ShFunction
              name: eapply_user
              body: 
                (command.BraceGroup
                  children: [
                    (command.AndOr
                      ops: [Op_DPipe]
                      children: [
                        (command.DBracket
                          expr: 
                            (bool_expr.Binary
                              op_id: BoolBinary_GlobDEqual
                              left: {(${ VSub_Name EBUILD_PHASE)}
                              right: {(prepare)}
                            )
                        )
                        (C {(die)} 
                          {
                            (DQ ('eapply_user() called during invalid phase: ') 
                              (${ VSub_Name EBUILD_PHASE)
                            )
                          }
                        )
                      ]
                    )
                    (C {(local)} 
                      {(Lit_VarLike 'tagfile=') (${ VSub_Name T) (/.portage_user_patches_applied)}
                    )
                    (command.AndOr
                      ops: [Op_DAmp]
                      children: [
                        (command.DBracket
                          expr: (bool_expr.Unary op_id:BoolUnary_f child:{(${ VSub_Name tagfile)})
                        )
                        (command.ControlFlow
                          token: <ControlFlow_Return return>
                        )
                      ]
                    )
                    (command.Simple
                      redirects: [
                        (redir.Redir
                          op: <Redir_DGreat '>>'>
                          fd: 16777215
                          arg_word: {(DQ (${ VSub_Name tagfile))}
                        )
                      ]
                    )
                    (C {(local)} 
                      {(Lit_VarLike 'basedir=') 
                        (braced_var_sub
                          token: <VSub_Name PORTAGE_CONFIGROOT>
                          suffix_op: (suffix_op.Unary op_id:VOp1_Percent arg_word:{(Lit_Slash /)})
                        ) (/etc/portage/patches)
                      }
                    )
                    (C {(local)} {(applied)} {(d)} {(f)})
                    (C {(local)} {(-A)} {(_eapply_user_patches)})
                    (C {(local)} 
                      {(Lit_VarLike 'prev_shopt=') 
                        (command_sub
                          left_token: <Left_DollarParen '$('>
                          command_list: 
                            (command.CommandList
                              children: [(C {(shopt)} {(-p)} {(nullglob)})]
                            )
                        )
                      }
                    )
                    (C {(shopt)} {(-s)} {(nullglob)})
                    (command.ForEach
                      iter_name: d
                      iter_words: [
                        (word.BracedTree
                          parts: [
                            (DQ (${ VSub_Name basedir))
                            (/)
                            (${ VSub_Name CATEGORY)
                            (/)
                            (word_part.BracedTuple
                              words: [
                                {(${ VSub_Name P) (-) (${ VSub_Name PR)}
                                {(${ VSub_Name P)}
                                {(${ VSub_Name PN)}
                              ]
                            )
                            (word_part.BracedTuple
                              words: [
                                {(Lit_Other ':') 
                                  (braced_var_sub
                                    token: <VSub_Name SLOT>
                                    suffix_op: 
                                      (suffix_op.Unary
                                        op_id: VOp1_Percent
                                        arg_word: {(Lit_Slash /) ('*')}
                                      )
                                  )
                                }
                                {}
                              ]
                            )
                          ]
                        )
                      ]
                      do_arg_iter: F
                      body: 
                        (command.DoGroup
                          children: [
                            (command.ForEach
                              iter_name: f
                              iter_words: [{(DQ (${ VSub_Name d)) (/) (Lit_Star '*')}]
                              do_arg_iter: F
                              body: 
                                (command.DoGroup
                                  children: [
                                    (command.If
                                      arms: [
                                        (if_arm
                                          cond: [
                                            (command.Sentence
                                              child: 
                                                (command.DBracket
                                                  expr: 
                                                    (bool_expr.LogicalAnd
                                                      left: 
                                                        (bool_expr.LogicalOr
                                                          left: 
                                                            (bool_expr.Binary
                                                              op_id: BoolBinary_GlobDEqual
                                                              left: {(${ VSub_Name f)}
                                                              right: {(Lit_Other '*') (.diff)}
                                                            )
                                                          right: 
                                                            (bool_expr.Binary
                                                              op_id: BoolBinary_GlobDEqual
                                                              left: {(${ VSub_Name f)}
                                                              right: {(Lit_Other '*') (.patch)}
                                                            )
                                                        )
                                                      right: 
                                                        (bool_expr.Unary
                                                          op_id: BoolUnary_z
                                                          child: 
                                                            {
                                                              (braced_var_sub
                                                                token: 
                                                                  <VSub_Name _eapply_user_patches>
                                                                bracket_op: 
                                                                  (bracket_op.ArrayIndex
                                                                    expr: 
                                                                      (arith_expr.ArithWord
                                                                        w: 
                                                                          {
                                                                            (braced_var_sub
                                                                              token: <VSub_Name f>
                                                                              suffix_op: 
                                                                                (suffix_op.Unary
                                                                                  op_id: VOp1_DPound
                                                                                  arg_word: 
                                                                                    {('*') 
                                                                                      (Lit_Slash /)
                                                                                    }
                                                                                )
                                                                            )
                                                                          }
                                                                      )
                                                                  )
                                                              )
                                                            }
                                                        )
                                                    )
                                                )
                                              terminator: <Op_Semi ';'>
                                            )
                                          ]
                                          action: [
                                            (command.ShAssignment
                                              pairs: [
                                                (assign_pair
                                                  lhs: 
                                                    (sh_lhs_expr.IndexedName
                                                      name: _eapply_user_patches
                                                      index: 
                                                        (arith_expr.ArithWord
                                                          w: 
                                                            {
                                                              (braced_var_sub
                                                                token: <VSub_Name f>
                                                                suffix_op: 
                                                                  (suffix_op.Unary
                                                                    op_id: VOp1_DPound
                                                                    arg_word: {('*') (Lit_Slash /)}
                                                                  )
                                                              )
                                                            }
                                                        )
                                                    )
                                                  op: Equal
                                                  rhs: {(${ VSub_Name f)}
                                                )
                                              ]
                                            )
                                          ]
                                        )
                                      ]
                                    )
                                  ]
                                )
                            )
                          ]
                        )
                    )
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.DBracket
                                  expr: 
                                    (bool_expr.Binary
                                      op_id: BoolBinary_gt
                                      left: 
                                        {
                                          (braced_var_sub
                                            token: <VSub_Name _eapply_user_patches>
                                            prefix_op: VSub_Pound
                                            bracket_op: (bracket_op.WholeArray op_id:Lit_At)
                                          )
                                        }
                                      right: {(0)}
                                    )
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (command.WhileUntil
                              keyword: <KW_While while>
                              cond: [
                                (command.Sentence
                                  child: (C {(read)} {(-r)} {(-d)} {(SQ )} {(f)})
                                  terminator: <Op_Semi ';'>
                                )
                              ]
                              body: 
                                (command.DoGroup
                                  children: [
                                    (command.ShAssignment
                                      pairs: [
                                        (assign_pair
                                          lhs: (sh_lhs_expr.Name name:f)
                                          op: Equal
                                          rhs: 
                                            {
                                              (braced_var_sub
                                                token: <VSub_Name _eapply_user_patches>
                                                bracket_op: 
                                                  (bracket_op.ArrayIndex
                                                    expr: (arith_expr.ArithWord w:{(${ VSub_Name f)})
                                                  )
                                              )
                                            }
                                        )
                                      ]
                                    )
                                    (command.If
                                      arms: [
                                        (if_arm
                                          cond: [
                                            (command.Sentence
                                              child: 
                                                (command.DBracket
                                                  expr: 
                                                    (bool_expr.Unary
                                                      op_id: BoolUnary_s
                                                      child: {(${ VSub_Name f)}
                                                    )
                                                )
                                              terminator: <Op_Semi ';'>
                                            )
                                          ]
                                          action: [
                                            (C {(eapply)} {(DQ (${ VSub_Name f))})
                                            (command.ShAssignment
                                              pairs: [
                                                (assign_pair
                                                  lhs: (sh_lhs_expr.Name name:applied)
                                                  op: Equal
                                                  rhs: {(1)}
                                                )
                                              ]
                                            )
                                          ]
                                        )
                                      ]
                                    )
                                  ]
                                )
                              redirects: [
                                (redir.Redir
                                  op: <Redir_Less '<'>
                                  fd: 16777215
                                  arg_word: 
                                    {
                                      (command_sub
                                        left_token: <Left_ProcSubIn '<('>
                                        command_list: 
                                          (command.CommandList
                                            children: [
                                              (command.Pipeline
                                                children: [
                                                  (C {(printf)} {(--)} {(SQ <'%s\\0'>)} 
                                                    {
                                                      (DQ 
                                                        (braced_var_sub
                                                          token: <VSub_Name _eapply_user_patches>
                                                          prefix_op: VSub_Bang
                                                          bracket_op: 
                                                            (bracket_op.WholeArray
                                                              op_id: Lit_At
                                                            )
                                                        )
                                                      )
                                                    }
                                                  )
                                                  (command.Simple
                                                    words: [{(sort)} {(-z)}]
                                                    more_env: [(env_pair name:LC_ALL val:{(C)})]
                                                  )
                                                ]
                                                negated: F
                                              )
                                            ]
                                          )
                                      )
                                    }
                                )
                              ]
                            )
                          ]
                        )
                      ]
                    )
                    (C {(${ VSub_Name prev_shopt)})
                    (command.AndOr
                      ops: [Op_DAmp]
                      children: [
                        (command.DBracket
                          expr: (bool_expr.Unary op_id:BoolUnary_n child:{(${ VSub_Name applied)})
                        )
                        (C {(ewarn)} {(DQ ('User patches applied.'))})
                      ]
                    )
                  ]
                )
            )
          ]
        )
      ]
    )
    (command.If
      arms: [
        (if_arm
          cond: [(command.Sentence child:(C {(___eapi_has_in_iuse)}) terminator:<Op_Semi ';'>)]
          action: [
            (command.ShFunction
              name: in_iuse
              body: 
                (command.BraceGroup
                  children: [
                    (C {(local)} {(Lit_VarLike 'use=') (${ VSub_Number 1)})
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.DBracket
                                  expr: 
                                    (bool_expr.Unary
                                      op_id: BoolUnary_z
                                      child: {(DQ (${ VSub_Name use))}
                                    )
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (command.Simple
                              words: [{(echo)} {(DQ ('!!! in_iuse() called without a parameter.'))}]
                              redirects: [
                                (redir.Redir
                                  op: <Redir_GreatAnd '>&'>
                                  fd: 16777215
                                  arg_word: {(2)}
                                )
                              ]
                            )
                            (command.Simple
                              words: [{(echo)} {(DQ ('!!! in_iuse <USEFLAG>'))}]
                              redirects: [
                                (redir.Redir
                                  op: <Redir_GreatAnd '>&'>
                                  fd: 16777215
                                  arg_word: {(2)}
                                )
                              ]
                            )
                            (C {(die)} {(DQ ('in_iuse() called without a parameter'))})
                          ]
                        )
                      ]
                    )
                    (C {(local)} 
                      {(Lit_VarLike 'liuse=') 
                        (sh_array_literal
                          left: <Op_LParen '('>
                          words: [{(${ VSub_Name IUSE_EFFECTIVE)}]
                        )
                      }
                    )
                    (C {(has)} {(DQ (${ VSub_Name use))} 
                      {
                        (DQ 
                          (braced_var_sub
                            token: <VSub_Name liuse>
                            bracket_op: (bracket_op.WholeArray op_id:Lit_At)
                            suffix_op: (suffix_op.Unary op_id:VOp1_Pound arg_word:{('[+-]')})
                          )
                        )
                      }
                    )
                  ]
                )
            )
          ]
        )
      ]
    )
    (command.If
      arms: [
        (if_arm
          cond: [
            (command.Sentence
              child: (C {(___eapi_has_master_repositories)})
              terminator: <Op_Semi ';'>
            )
          ]
          action: [
            (command.ShFunction
              name: master_repositories
              body: 
                (command.BraceGroup
                  children: [
                    (C {(local)} {(output)} {(Lit_VarLike 'repository=') ($ VSub_Number '$1')} {(retval)})
                    (C {(shift)})
                    (command.AndOr
                      ops: [Op_DAmp]
                      children: [
                        (command.DBracket
                          expr: 
                            (bool_expr.Binary
                              op_id: BoolBinary_gt
                              left: {($ VSub_Pound '$#')}
                              right: {(0)}
                            )
                        )
                        (C {(die)} 
                          {
                            (DQ 
                              (braced_var_sub
                                token: <VSub_Name FUNCNAME>
                                bracket_op: 
                                  (bracket_op.ArrayIndex
                                    expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                  )
                              ) (': unused argument(s): ') ($ VSub_Star '$*')
                            )
                          }
                        )
                      ]
                    )
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.DBracket
                                  expr: 
                                    (bool_expr.Unary
                                      op_id: BoolUnary_n
                                      child: {(${ VSub_Name PORTAGE_IPC_DAEMON)}
                                    )
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (C {(DQ (${ VSub_Name PORTAGE_BIN_PATH) (/ebuild-ipc))} 
                              {(master_repositories)} {(DQ (${ VSub_Name EROOT))} {(DQ (${ VSub_Name repository))}
                            )
                          ]
                        )
                      ]
                      else_action: [
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:output)
                              op: Equal
                              rhs: 
                                {
                                  (command_sub
                                    left_token: <Left_DollarParen '$('>
                                    command_list: 
                                      (command.CommandList
                                        children: [
                                          (C 
                                            {
                                              (DQ (${ VSub_Name PORTAGE_BIN_PATH) 
                                                (/ebuild-helpers/portageq)
                                              )
                                            } {(master_repositories)} {(DQ (${ VSub_Name EROOT))} {(DQ (${ VSub_Name repository))}
                                          )
                                        ]
                                      )
                                  )
                                }
                            )
                          ]
                        )
                      ]
                    )
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:retval)
                          op: Equal
                          rhs: {($ VSub_QMark '$?')}
                        )
                      ]
                    )
                    (command.AndOr
                      ops: [Op_DAmp]
                      children: [
                        (command.DBracket
                          expr: (bool_expr.Unary op_id:BoolUnary_n child:{(${ VSub_Name output)})
                        )
                        (C {(echo)} {(DQ (${ VSub_Name output))})
                      ]
                    )
                    (command.Case
                      to_match: {(DQ (${ VSub_Name retval))}
                      arms: [
                        (case_arm
                          pat_list: [{(0)} {(1)}]
                          action: [
                            (command.ControlFlow
                              token: <ControlFlow_Return return>
                              arg_word: {(${ VSub_Name retval)}
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(2)}]
                          action: [
                            (C {(die)} 
                              {
                                (DQ 
                                  (braced_var_sub
                                    token: <VSub_Name FUNCNAME>
                                    bracket_op: 
                                      (bracket_op.ArrayIndex
                                        expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                      )
                                  ) (': invalid repository: ') (${ VSub_Name repository)
                                )
                              }
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(Lit_Star '*')}]
                          action: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.DBracket
                                          expr: 
                                            (bool_expr.Unary
                                              op_id: BoolUnary_n
                                              child: {(${ VSub_Name PORTAGE_IPC_DAEMON)}
                                            )
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(die)} 
                                      {
                                        (DQ 
                                          (braced_var_sub
                                            token: <VSub_Name FUNCNAME>
                                            bracket_op: 
                                              (bracket_op.ArrayIndex
                                                expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                              )
                                          ) (': unexpected ebuild-ipc exit code: ') (${ VSub_Name retval)
                                        )
                                      }
                                    )
                                  ]
                                )
                              ]
                              else_action: [
                                (C {(die)} 
                                  {
                                    (DQ 
                                      (braced_var_sub
                                        token: <VSub_Name FUNCNAME>
                                        bracket_op: 
                                          (bracket_op.ArrayIndex
                                            expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                          )
                                      ) (': unexpected portageq exit code: ') (${ VSub_Name retval)
                                    )
                                  }
                                )
                              ]
                            )
                          ]
                        )
                      ]
                    )
                  ]
                )
            )
          ]
        )
      ]
    )
    (command.If
      arms: [
        (if_arm
          cond: [(command.Sentence child:(C {(___eapi_has_repository_path)}) terminator:<Op_Semi ';'>)]
          action: [
            (command.ShFunction
              name: repository_path
              body: 
                (command.BraceGroup
                  children: [
                    (C {(local)} {(output)} {(Lit_VarLike 'repository=') ($ VSub_Number '$1')} {(retval)})
                    (C {(shift)})
                    (command.AndOr
                      ops: [Op_DAmp]
                      children: [
                        (command.DBracket
                          expr: 
                            (bool_expr.Binary
                              op_id: BoolBinary_gt
                              left: {($ VSub_Pound '$#')}
                              right: {(0)}
                            )
                        )
                        (C {(die)} 
                          {
                            (DQ 
                              (braced_var_sub
                                token: <VSub_Name FUNCNAME>
                                bracket_op: 
                                  (bracket_op.ArrayIndex
                                    expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                  )
                              ) (': unused argument(s): ') ($ VSub_Star '$*')
                            )
                          }
                        )
                      ]
                    )
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.DBracket
                                  expr: 
                                    (bool_expr.Unary
                                      op_id: BoolUnary_n
                                      child: {(${ VSub_Name PORTAGE_IPC_DAEMON)}
                                    )
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (C {(DQ (${ VSub_Name PORTAGE_BIN_PATH) (/ebuild-ipc))} {(repository_path)} 
                              {(DQ (${ VSub_Name EROOT))} {(DQ (${ VSub_Name repository))}
                            )
                          ]
                        )
                      ]
                      else_action: [
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:output)
                              op: Equal
                              rhs: 
                                {
                                  (command_sub
                                    left_token: <Left_DollarParen '$('>
                                    command_list: 
                                      (command.CommandList
                                        children: [
                                          (C 
                                            {
                                              (DQ (${ VSub_Name PORTAGE_BIN_PATH) 
                                                (/ebuild-helpers/portageq)
                                              )
                                            } {(get_repo_path)} {(DQ (${ VSub_Name EROOT))} {(DQ (${ VSub_Name repository))}
                                          )
                                        ]
                                      )
                                  )
                                }
                            )
                          ]
                        )
                      ]
                    )
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:retval)
                          op: Equal
                          rhs: {($ VSub_QMark '$?')}
                        )
                      ]
                    )
                    (command.AndOr
                      ops: [Op_DAmp]
                      children: [
                        (command.DBracket
                          expr: (bool_expr.Unary op_id:BoolUnary_n child:{(${ VSub_Name output)})
                        )
                        (C {(echo)} {(DQ (${ VSub_Name output))})
                      ]
                    )
                    (command.Case
                      to_match: {(DQ (${ VSub_Name retval))}
                      arms: [
                        (case_arm
                          pat_list: [{(0)} {(1)}]
                          action: [
                            (command.ControlFlow
                              token: <ControlFlow_Return return>
                              arg_word: {(${ VSub_Name retval)}
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(2)}]
                          action: [
                            (C {(die)} 
                              {
                                (DQ 
                                  (braced_var_sub
                                    token: <VSub_Name FUNCNAME>
                                    bracket_op: 
                                      (bracket_op.ArrayIndex
                                        expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                      )
                                  ) (': invalid repository: ') (${ VSub_Name repository)
                                )
                              }
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(Lit_Star '*')}]
                          action: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.DBracket
                                          expr: 
                                            (bool_expr.Unary
                                              op_id: BoolUnary_n
                                              child: {(${ VSub_Name PORTAGE_IPC_DAEMON)}
                                            )
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(die)} 
                                      {
                                        (DQ 
                                          (braced_var_sub
                                            token: <VSub_Name FUNCNAME>
                                            bracket_op: 
                                              (bracket_op.ArrayIndex
                                                expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                              )
                                          ) (': unexpected ebuild-ipc exit code: ') (${ VSub_Name retval)
                                        )
                                      }
                                    )
                                  ]
                                )
                              ]
                              else_action: [
                                (C {(die)} 
                                  {
                                    (DQ 
                                      (braced_var_sub
                                        token: <VSub_Name FUNCNAME>
                                        bracket_op: 
                                          (bracket_op.ArrayIndex
                                            expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                          )
                                      ) (': unexpected portageq exit code: ') (${ VSub_Name retval)
                                    )
                                  }
                                )
                              ]
                            )
                          ]
                        )
                      ]
                    )
                  ]
                )
            )
          ]
        )
      ]
    )
    (command.If
      arms: [
        (if_arm
          cond: [
            (command.Sentence
              child: (C {(___eapi_has_available_eclasses)})
              terminator: <Op_Semi ';'>
            )
          ]
          action: [
            (command.ShFunction
              name: available_eclasses
              body: 
                (command.BraceGroup
                  children: [
                    (C {(local)} {(output)} 
                      {(Lit_VarLike 'repository=') (${ VSub_Name PORTAGE_REPO_NAME)} {(retval)}
                    )
                    (command.AndOr
                      ops: [Op_DAmp]
                      children: [
                        (command.DBracket
                          expr: 
                            (bool_expr.Binary
                              op_id: BoolBinary_gt
                              left: {($ VSub_Pound '$#')}
                              right: {(0)}
                            )
                        )
                        (C {(die)} 
                          {
                            (DQ 
                              (braced_var_sub
                                token: <VSub_Name FUNCNAME>
                                bracket_op: 
                                  (bracket_op.ArrayIndex
                                    expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                  )
                              ) (': unused argument(s): ') ($ VSub_Star '$*')
                            )
                          }
                        )
                      ]
                    )
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.DBracket
                                  expr: 
                                    (bool_expr.Unary
                                      op_id: BoolUnary_n
                                      child: {(${ VSub_Name PORTAGE_IPC_DAEMON)}
                                    )
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (C {(DQ (${ VSub_Name PORTAGE_BIN_PATH) (/ebuild-ipc))} 
                              {(available_eclasses)} {(DQ (${ VSub_Name EROOT))} {(DQ (${ VSub_Name repository))}
                            )
                          ]
                        )
                      ]
                      else_action: [
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:output)
                              op: Equal
                              rhs: 
                                {
                                  (command_sub
                                    left_token: <Left_DollarParen '$('>
                                    command_list: 
                                      (command.CommandList
                                        children: [
                                          (C 
                                            {
                                              (DQ (${ VSub_Name PORTAGE_BIN_PATH) 
                                                (/ebuild-helpers/portageq)
                                              )
                                            } {(available_eclasses)} {(DQ (${ VSub_Name EROOT))} {(DQ (${ VSub_Name repository))}
                                          )
                                        ]
                                      )
                                  )
                                }
                            )
                          ]
                        )
                      ]
                    )
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:retval)
                          op: Equal
                          rhs: {($ VSub_QMark '$?')}
                        )
                      ]
                    )
                    (command.AndOr
                      ops: [Op_DAmp]
                      children: [
                        (command.DBracket
                          expr: (bool_expr.Unary op_id:BoolUnary_n child:{(${ VSub_Name output)})
                        )
                        (C {(echo)} {(DQ (${ VSub_Name output))})
                      ]
                    )
                    (command.Case
                      to_match: {(DQ (${ VSub_Name retval))}
                      arms: [
                        (case_arm
                          pat_list: [{(0)} {(1)}]
                          action: [
                            (command.ControlFlow
                              token: <ControlFlow_Return return>
                              arg_word: {(${ VSub_Name retval)}
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(2)}]
                          action: [
                            (C {(die)} 
                              {
                                (DQ 
                                  (braced_var_sub
                                    token: <VSub_Name FUNCNAME>
                                    bracket_op: 
                                      (bracket_op.ArrayIndex
                                        expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                      )
                                  ) (': invalid repository: ') (${ VSub_Name repository)
                                )
                              }
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(Lit_Star '*')}]
                          action: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.DBracket
                                          expr: 
                                            (bool_expr.Unary
                                              op_id: BoolUnary_n
                                              child: {(${ VSub_Name PORTAGE_IPC_DAEMON)}
                                            )
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(die)} 
                                      {
                                        (DQ 
                                          (braced_var_sub
                                            token: <VSub_Name FUNCNAME>
                                            bracket_op: 
                                              (bracket_op.ArrayIndex
                                                expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                              )
                                          ) (': unexpected ebuild-ipc exit code: ') (${ VSub_Name retval)
                                        )
                                      }
                                    )
                                  ]
                                )
                              ]
                              else_action: [
                                (C {(die)} 
                                  {
                                    (DQ 
                                      (braced_var_sub
                                        token: <VSub_Name FUNCNAME>
                                        bracket_op: 
                                          (bracket_op.ArrayIndex
                                            expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                          )
                                      ) (': unexpected portageq exit code: ') (${ VSub_Name retval)
                                    )
                                  }
                                )
                              ]
                            )
                          ]
                        )
                      ]
                    )
                  ]
                )
            )
          ]
        )
      ]
    )
    (command.If
      arms: [
        (if_arm
          cond: [(command.Sentence child:(C {(___eapi_has_eclass_path)}) terminator:<Op_Semi ';'>)]
          action: [
            (command.ShFunction
              name: eclass_path
              body: 
                (command.BraceGroup
                  children: [
                    (C {(local)} {(Lit_VarLike 'eclass=') ($ VSub_Number '$1')} {(output)} 
                      {(Lit_VarLike 'repository=') (${ VSub_Name PORTAGE_REPO_NAME)} {(retval)}
                    )
                    (C {(shift)})
                    (command.AndOr
                      ops: [Op_DAmp]
                      children: [
                        (command.DBracket
                          expr: 
                            (bool_expr.Binary
                              op_id: BoolBinary_gt
                              left: {($ VSub_Pound '$#')}
                              right: {(0)}
                            )
                        )
                        (C {(die)} 
                          {
                            (DQ 
                              (braced_var_sub
                                token: <VSub_Name FUNCNAME>
                                bracket_op: 
                                  (bracket_op.ArrayIndex
                                    expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                  )
                              ) (': unused argument(s): ') ($ VSub_Star '$*')
                            )
                          }
                        )
                      ]
                    )
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.DBracket
                                  expr: 
                                    (bool_expr.Unary
                                      op_id: BoolUnary_n
                                      child: {(${ VSub_Name PORTAGE_IPC_DAEMON)}
                                    )
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (C {(DQ (${ VSub_Name PORTAGE_BIN_PATH) (/ebuild-ipc))} {(eclass_path)} 
                              {(DQ (${ VSub_Name EROOT))} {(DQ (${ VSub_Name repository))} {(DQ (${ VSub_Name eclass))}
                            )
                          ]
                        )
                      ]
                      else_action: [
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:output)
                              op: Equal
                              rhs: 
                                {
                                  (command_sub
                                    left_token: <Left_DollarParen '$('>
                                    command_list: 
                                      (command.CommandList
                                        children: [
                                          (C 
                                            {
                                              (DQ (${ VSub_Name PORTAGE_BIN_PATH) 
                                                (/ebuild-helpers/portageq)
                                              )
                                            } {(eclass_path)} {(DQ (${ VSub_Name EROOT))} {(DQ (${ VSub_Name repository))} {(DQ (${ VSub_Name eclass))}
                                          )
                                        ]
                                      )
                                  )
                                }
                            )
                          ]
                        )
                      ]
                    )
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:retval)
                          op: Equal
                          rhs: {($ VSub_QMark '$?')}
                        )
                      ]
                    )
                    (command.AndOr
                      ops: [Op_DAmp]
                      children: [
                        (command.DBracket
                          expr: (bool_expr.Unary op_id:BoolUnary_n child:{(${ VSub_Name output)})
                        )
                        (C {(echo)} {(DQ (${ VSub_Name output))})
                      ]
                    )
                    (command.Case
                      to_match: {(DQ (${ VSub_Name retval))}
                      arms: [
                        (case_arm
                          pat_list: [{(0)} {(1)}]
                          action: [
                            (command.ControlFlow
                              token: <ControlFlow_Return return>
                              arg_word: {(${ VSub_Name retval)}
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(2)}]
                          action: [
                            (C {(die)} 
                              {
                                (DQ 
                                  (braced_var_sub
                                    token: <VSub_Name FUNCNAME>
                                    bracket_op: 
                                      (bracket_op.ArrayIndex
                                        expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                      )
                                  ) (': invalid repository: ') (${ VSub_Name repository)
                                )
                              }
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(Lit_Star '*')}]
                          action: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.DBracket
                                          expr: 
                                            (bool_expr.Unary
                                              op_id: BoolUnary_n
                                              child: {(${ VSub_Name PORTAGE_IPC_DAEMON)}
                                            )
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(die)} 
                                      {
                                        (DQ 
                                          (braced_var_sub
                                            token: <VSub_Name FUNCNAME>
                                            bracket_op: 
                                              (bracket_op.ArrayIndex
                                                expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                              )
                                          ) (': unexpected ebuild-ipc exit code: ') (${ VSub_Name retval)
                                        )
                                      }
                                    )
                                  ]
                                )
                              ]
                              else_action: [
                                (C {(die)} 
                                  {
                                    (DQ 
                                      (braced_var_sub
                                        token: <VSub_Name FUNCNAME>
                                        bracket_op: 
                                          (bracket_op.ArrayIndex
                                            expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                          )
                                      ) (': unexpected portageq exit code: ') (${ VSub_Name retval)
                                    )
                                  }
                                )
                              ]
                            )
                          ]
                        )
                      ]
                    )
                  ]
                )
            )
          ]
        )
      ]
    )
    (command.If
      arms: [
        (if_arm
          cond: [(command.Sentence child:(C {(___eapi_has_license_path)}) terminator:<Op_Semi ';'>)]
          action: [
            (command.ShFunction
              name: license_path
              body: 
                (command.BraceGroup
                  children: [
                    (C {(local)} {(Lit_VarLike 'license=') ($ VSub_Number '$1')} {(output)} 
                      {(Lit_VarLike 'repository=') (${ VSub_Name PORTAGE_REPO_NAME)} {(retval)}
                    )
                    (C {(shift)})
                    (command.AndOr
                      ops: [Op_DAmp]
                      children: [
                        (command.DBracket
                          expr: 
                            (bool_expr.Binary
                              op_id: BoolBinary_gt
                              left: {($ VSub_Pound '$#')}
                              right: {(0)}
                            )
                        )
                        (C {(die)} 
                          {
                            (DQ 
                              (braced_var_sub
                                token: <VSub_Name FUNCNAME>
                                bracket_op: 
                                  (bracket_op.ArrayIndex
                                    expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                  )
                              ) (': unused argument(s): ') ($ VSub_Star '$*')
                            )
                          }
                        )
                      ]
                    )
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.DBracket
                                  expr: 
                                    (bool_expr.Unary
                                      op_id: BoolUnary_n
                                      child: {(${ VSub_Name PORTAGE_IPC_DAEMON)}
                                    )
                                )
                              terminator: <Op_Semi ';'>
                            )
                          ]
                          action: [
                            (C {(DQ (${ VSub_Name PORTAGE_BIN_PATH) (/ebuild-ipc))} {(license_path)} 
                              {(DQ (${ VSub_Name EROOT))} {(DQ (${ VSub_Name repository))} {(DQ (${ VSub_Name license))}
                            )
                          ]
                        )
                      ]
                      else_action: [
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:output)
                              op: Equal
                              rhs: 
                                {
                                  (command_sub
                                    left_token: <Left_DollarParen '$('>
                                    command_list: 
                                      (command.CommandList
                                        children: [
                                          (C 
                                            {
                                              (DQ (${ VSub_Name PORTAGE_BIN_PATH) 
                                                (/ebuild-helpers/portageq)
                                              )
                                            } {(license_path)} {(DQ (${ VSub_Name EROOT))} {(DQ (${ VSub_Name repository))} 
                                            {(DQ (${ VSub_Name license))}
                                          )
                                        ]
                                      )
                                  )
                                }
                            )
                          ]
                        )
                      ]
                    )
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:retval)
                          op: Equal
                          rhs: {($ VSub_QMark '$?')}
                        )
                      ]
                    )
                    (command.AndOr
                      ops: [Op_DAmp]
                      children: [
                        (command.DBracket
                          expr: (bool_expr.Unary op_id:BoolUnary_n child:{(${ VSub_Name output)})
                        )
                        (C {(echo)} {(DQ (${ VSub_Name output))})
                      ]
                    )
                    (command.Case
                      to_match: {(DQ (${ VSub_Name retval))}
                      arms: [
                        (case_arm
                          pat_list: [{(0)} {(1)}]
                          action: [
                            (command.ControlFlow
                              token: <ControlFlow_Return return>
                              arg_word: {(${ VSub_Name retval)}
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(2)}]
                          action: [
                            (C {(die)} 
                              {
                                (DQ 
                                  (braced_var_sub
                                    token: <VSub_Name FUNCNAME>
                                    bracket_op: 
                                      (bracket_op.ArrayIndex
                                        expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                      )
                                  ) (': invalid repository: ') (${ VSub_Name repository)
                                )
                              }
                            )
                          ]
                        )
                        (case_arm
                          pat_list: [{(Lit_Star '*')}]
                          action: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (command.Sentence
                                      child: 
                                        (command.DBracket
                                          expr: 
                                            (bool_expr.Unary
                                              op_id: BoolUnary_n
                                              child: {(${ VSub_Name PORTAGE_IPC_DAEMON)}
                                            )
                                        )
                                      terminator: <Op_Semi ';'>
                                    )
                                  ]
                                  action: [
                                    (C {(die)} 
                                      {
                                        (DQ 
                                          (braced_var_sub
                                            token: <VSub_Name FUNCNAME>
                                            bracket_op: 
                                              (bracket_op.ArrayIndex
                                                expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                              )
                                          ) (': unexpected ebuild-ipc exit code: ') (${ VSub_Name retval)
                                        )
                                      }
                                    )
                                  ]
                                )
                              ]
                              else_action: [
                                (C {(die)} 
                                  {
                                    (DQ 
                                      (braced_var_sub
                                        token: <VSub_Name FUNCNAME>
                                        bracket_op: 
                                          (bracket_op.ArrayIndex
                                            expr: (arith_expr.ArithWord w:{(Lit_Digits 0)})
                                          )
                                      ) (': unexpected portageq exit code: ') (${ VSub_Name retval)
                                    )
                                  }
                                )
                              ]
                            )
                          ]
                        )
                      ]
                    )
                  ]
                )
            )
          ]
        )
      ]
    )
    (command.If
      arms: [
        (if_arm
          cond: [
            (command.Sentence
              child: (C {(___eapi_has_package_manager_build_user)})
              terminator: <Op_Semi ';'>
            )
          ]
          action: [
            (command.ShFunction
              name: package_manager_build_user
              body: 
                (command.BraceGroup
                  children: [(C {(echo)} {(DQ (${ VSub_Name PORTAGE_BUILD_USER))})]
                )
            )
          ]
        )
      ]
    )
    (command.If
      arms: [
        (if_arm
          cond: [
            (command.Sentence
              child: (C {(___eapi_has_package_manager_build_group)})
              terminator: <Op_Semi ';'>
            )
          ]
          action: [
            (command.ShFunction
              name: package_manager_build_group
              body: 
                (command.BraceGroup
                  children: [(C {(echo)} {(DQ (${ VSub_Name PORTAGE_BUILD_GROUP))})]
                )
            )
          ]
        )
      ]
    )
  ]
)