(CommandList children: [ (FuncDef name: log_error_and_exit body: (BraceGroup children: [ (C {(echo)} {($ VSub_Number '$0') (Lit_Other ':')} {($ VSub_At '$@')}) (ControlFlow token:<ControlFlow_Exit exit> arg_word:{(1)}) ] spids: [33] ) spids: [29 32] ) (FuncDef name: process_entry body: (BraceGroup children: [ (If arms: [ (if_arm cond: [ (Sentence child: (AndOr ops: [Op_DPipe] children: [ (C {(Lit_Other '[')} {(-z)} {(DQ ($ VSub_Number '$1'))} {(Lit_Other ']')}) (C {(Lit_Other '[')} {(-z)} {(DQ ($ VSub_Number '$2'))} {(Lit_Other ']')}) ] ) terminator: <Op_Semi ';'> ) ] action: [(C {(log_error_and_exit)} {(DQ ('bad arguments to process_entry()'))})] spids: [16777215 83] ) ] spids: [16777215 93] ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:root) op: Equal rhs: {(DQ ($ VSub_Number '$1'))} spids: [98] ) ] spids: [96] ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:localpath) op: Equal rhs: {(DQ ($ VSub_Number '$2'))} spids: [106] ) ] spids: [104] ) (Pipeline children: [(C {(echo)} {($ VSub_Name '$localpath')}) (C {(grep)} {(-qs)} {(SQ <'^/'>)})] negated: F ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {($ VSub_QMark '$?')} {(-ne)} {(0)} {(Lit_Other ']')}) terminator: <Op_Semi ';'> ) ] action: [ (C {(log_error_and_exit)} {($ VSub_Name '$localpath')} {(does)} {(not)} {(start)} {(with)} {(/)} ) ] spids: [16777215 141] ) ] spids: [16777215 159] ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:entry) op: Equal rhs: {(DQ ($ VSub_Name '$root') ($ VSub_Name '$localpath'))} spids: [164] ) ] spids: [162] ) (C {(echo)} {(-L) ($ VSub_Name '$entry')}) (C {(echo)} {(-Wl) (Lit_Comma ',') (-rpath-link) (Lit_Other '=') ($ VSub_Name '$entry')}) ] spids: [55] ) spids: [51 54] ) (FuncDef name: process_ld_so_conf body: (BraceGroup children: [ (If arms: [ (if_arm cond: [ (Sentence child: (AndOr ops: [Op_DPipe] children: [ (C {(Lit_Other '[')} {(-z)} {(DQ ($ VSub_Number '$1'))} {(Lit_Other ']')}) (C {(Lit_Other '[')} {(-z)} {(DQ ($ VSub_Number '$2'))} {(Lit_Other ']')}) ] ) terminator: <Op_Semi ';'> ) ] action: [(C {(log_error_and_exit)} {(DQ ('bad arguments to process_ld_so_conf()'))})] spids: [16777215 220] ) ] spids: [16777215 230] ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:root) op: Equal rhs: {(DQ ($ VSub_Number '$1'))} spids: [235] ) ] spids: [233] ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:ld_so_conf) op: Equal rhs: {(DQ ($ VSub_Number '$2'))} spids: [243] ) ] spids: [241] ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:saved_pwd) op: Equal rhs: { (CommandSubPart command_list: (CommandList children:[(C {(pwd)})]) left_token: <Left_CommandSub '$('> spids: [257 259] ) } spids: [256] ) ] spids: [254] ) (C {(cd)} { (CommandSubPart command_list: (CommandList children: [(C {(dirname)} {(DQ ($ VSub_Name '$ld_so_conf'))})] ) left_token: <Left_CommandSub '$('> spids: [264 270] ) } ) (Pipeline children: [ (C {(cat)} {(DQ ($ VSub_Name '$ld_so_conf'))}) (WhileUntil keyword: <KW_While while> cond: [(Sentence child:(C {(read)} {(ENTRY)}) terminator:<Op_Semi ';'>)] body: (DoGroup children: [ (Pipeline children: [ (C {(echo)} {(DQ ($ VSub_Name '$ENTRY'))}) (C {(grep)} {(-qs)} {(Lit_Other '^') (include)}) ] negated: F ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {($ VSub_QMark '$?')} {(-eq)} {(0)} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:included_files) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(echo)} {(DQ ($ VSub_Name '$ENTRY'))}) (C {(sed)} {(SQ <'s/^include //'>)}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [329 343] ) } spids: [328] ) ] spids: [326] ) (Pipeline children: [ (C {(echo)} {(DQ ($ VSub_Name '$included_files'))}) (C {(grep)} {(-qs)} {(Lit_Other '^') (/)}) ] negated: F ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {($ VSub_QMark '$?')} {(-eq)} {(0)} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (If arms: [ (if_arm cond: [ (Sentence child: (SimpleCommand words: [ {(ls)} {($ VSub_Name '$root') ($ VSub_Name '$included_files') } ] redirects: [ (Redir op: <Redir_Great '>'> fd: 16777215 arg_word: {(/dev/null)} ) (Redir op: <Redir_GreatAnd '2>&'> fd: 2 arg_word: {(1)} ) ] ) terminator: <Op_Semi ';'> ) ] action: [ (ForEach iter_name: inc_file iter_words: [ {($ VSub_Name '$root') ($ VSub_Name '$included_files') } ] do_arg_iter: F body: (DoGroup children: [ (C {(process_ld_so_conf)} {(DQ ($ VSub_Name '$root'))} {(DQ ($ VSub_Name '$inc_file'))} ) ] spids: [406 420] ) spids: [401 404] ) ] spids: [16777215 393] ) ] spids: [16777215 423] ) ] spids: [16777215 375] ) ] else_action: [ (If arms: [ (if_arm cond: [ (Sentence child: (SimpleCommand words: [ {(ls)} { (CommandSubPart command_list: (CommandList children: [(C {(pwd)})] ) left_token: <Left_CommandSub '$('> spids: [433 435] ) (/) ($ VSub_Name '$included_files') } ] redirects: [ (Redir op: <Redir_Great '>'> fd: 16777215 arg_word: {(/dev/null)} ) (Redir op: <Redir_GreatAnd '2>&'> fd: 2 arg_word: {(1)} ) ] ) terminator: <Op_Semi ';'> ) ] action: [ (ForEach iter_name: inc_file iter_words: [ { (CommandSubPart command_list: (CommandList children: [(C {(pwd)})] ) left_token: <Left_CommandSub '$('> spids: [456 458] ) (/) ($ VSub_Name '$included_files') } ] do_arg_iter: F body: (DoGroup children: [ (C {(process_ld_so_conf)} {(DQ ($ VSub_Name '$root'))} {(DQ ($ VSub_Name '$inc_file'))} ) ] spids: [463 477] ) spids: [455 461] ) ] spids: [16777215 447] ) ] spids: [16777215 480] ) ] spids: [426 483] ) (ControlFlow token: <ControlFlow_Continue continue> ) ] spids: [16777215 323] ) ] spids: [16777215 489] ) (Pipeline children: [ (C {(echo)} {(DQ ($ VSub_Name '$ENTRY'))}) (C {(grep)} {(-qs)} {(Lit_Other '^') (/)}) ] negated: F ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {($ VSub_QMark '$?')} {(-eq)} {(0)} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (C {(process_entry)} {(DQ ($ VSub_Name '$root'))} {(DQ ($ VSub_Name '$ENTRY'))} ) ] spids: [16777215 522] ) ] spids: [16777215 536] ) ] spids: [291 539] ) ) ] negated: F ) (C {(cd)} {(DQ ($ VSub_Name '$saved_pwd'))}) ] spids: [192] ) spids: [188 191] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {($ VSub_Pound '$#')} {(-ne)} {(1)} {(Lit_Other ']')}) terminator: <Op_Semi ';'> ) ] action: [ (C {(echo)} {(Usage)} {($ VSub_Number '$0')} {(/abspath/to/sysroot)}) (ControlFlow token:<ControlFlow_Exit exit> arg_word:{(1)}) ] spids: [16777215 573] ) ] spids: [16777215 589] ) (Pipeline children: [(C {(echo)} {($ VSub_Number '$1')}) (C {(grep)} {(-qs)} {(SQ <' '>)})] negated: F ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {($ VSub_QMark '$?')} {(-eq)} {(0)} {(Lit_Other ']')}) terminator: <Op_Semi ';'> ) ] action: [(C {(log_error_and_exit)} {($ VSub_Number '$1')} {(contains)} {(whitespace.)})] spids: [16777215 619] ) ] spids: [16777215 630] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:LD_SO_CONF) op: Equal rhs: {(DQ ($ VSub_Number '$1') (/etc/ld.so.conf))} spids: [633] ) ] spids: [633] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:LD_SO_CONF_D) op: Equal rhs: {(DQ ($ VSub_Number '$1') (/etc/ld.so.conf.d))} spids: [639] ) ] spids: [639] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(-e)} {(DQ ($ VSub_Name '$LD_SO_CONF'))} {(Lit_Other ']')}) terminator: <Op_Semi ';'> ) ] action: [ (Pipeline children: [ (C {(process_ld_so_conf)} {(DQ ($ VSub_Number '$1'))} {(DQ ($ VSub_Name '$LD_SO_CONF'))}) (C {(xargs)} {(echo)}) ] negated: F ) ] spids: [16777215 659] ) (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(-e)} {(DQ ($ VSub_Name '$LD_SO_CONF_D'))} {(Lit_Other ']')}) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [ {(find)} {(DQ ($ VSub_Name '$LD_SO_CONF_D'))} {(-maxdepth)} {(1)} {(-name)} {(SQ <'*.conf'>)} {(-print)} {(-quit)} ] redirects: [(Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(/dev/null)})] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {($ VSub_QMark '$?')} {(-eq)} {(0)} {(Lit_Other ']')}) terminator: <Op_Semi ';'> ) ] action: [ (Pipeline children: [ (ForEach iter_name: entry iter_words: [{($ VSub_Name '$LD_SO_CONF_D') (/) (Lit_Other '*') (.conf)}] do_arg_iter: F body: (DoGroup children: [ (C {(process_ld_so_conf)} {(DQ ($ VSub_Number '$1'))} {(DQ ($ VSub_Name '$entry'))} ) ] spids: [747 761] ) spids: [740 745] ) (C {(xargs)} {(echo)}) ] negated: F ) ] spids: [16777215 732] ) ] spids: [16777215 770] ) ] spids: [678 691] ) ] spids: [16777215 772] ) ] )