(CommandList children: [ (FuncDef name: echo_then_sudo body: (BraceGroup children: [ (SimpleCommand words: [{(echo)} {(DQ ('About to execute privileged command: ') ($ VSub_At '$@'))}] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[19])] ) (C {(sudo)} {(-k)} {(DQ ($ VSub_At '$@'))}) ] spids: [9] ) spids: [4 8] ) (FuncDef name: fixup_debuglink body: (BraceGroup children: [ (SimpleCommand words: [{(echo)} {(DQ ('begin fixup_debuglink'))}] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[54])] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:obj) op: Equal rhs: {(DQ ($ VSub_Number '$1'))} spids: [58] ) ] spids: [58] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:debuglink) op: Equal rhs: {(DQ ($ VSub_Number '$2'))} spids: [64] ) ] spids: [64] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:current_debuglink) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [(C {(read_debuglink)} {(DQ ($ VSub_Name '$obj'))})] ) left_token: <Left_CommandSub '$('> spids: [72 80] ) ) } spids: [70] ) ] spids: [70] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:has_debuglink) op: Equal rhs: {($ VSub_QMark '$?')} spids: [84] ) ] spids: [84] ) (If arms: [ (if_arm cond: [ (Sentence child: (AndOr ops: [Op_DAmp] children: [ (DBracket expr: (BoolBinary op_id: BoolBinary_eq left: {($ VSub_Name '$has_debuglink')} right: {(0)} ) ) (DBracket expr: (BoolBinary op_id: BoolBinary_GlobDEqual left: {(DQ ($ VSub_Name '$current_debuglink'))} right: {(DQ ($ VSub_Name '$debuglink'))} ) ) ] ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [ {(echo)} { (DQ ('detected that debuglink ') ($ VSub_Name '$debuglink_value') (' is already valid') ) } ] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[130])] ) (ControlFlow token:<ControlFlow_Return return> arg_word:{(0)}) ] spids: [16777215 119] ) ] else_action: [ (If arms: [ (if_arm cond: [ (Sentence child: (DBracket expr: (BoolBinary op_id: BoolBinary_eq left: {($ VSub_Name '$has_debuglink')} right: {(0)} ) ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [ {(echo)} { (DQ ('detected that debuglink ') ($ VSub_Name '$current_debuglink') (' needs fixing up to ') ($ VSub_Name '$debuglink') ) } ] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[168])] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:tmpfile) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children:[(C {(mktemp)})]) left_token: <Left_CommandSub '$('> spids: [178 180] ) ) } spids: [176] ) ] spids: [176] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:saved_ug) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (C {(stat)} {(-c)} {(DQ ('%u:%g'))} { (DQ (CommandSubPart command_list: (CommandList children: [ (C {(readlink)} {(-f)} {(DQ ($ VSub_Name '$obj'))} ) ] ) left_token: <Left_CommandSub '$('> spids: [197 207] ) ) } ) ] ) left_token: <Left_CommandSub '$('> spids: [186 210] ) ) } spids: [184] ) ] spids: [184] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:saved_mode) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (C {(stat)} {(-c)} {(DQ ('%a'))} { (DQ (CommandSubPart command_list: (CommandList children: [ (C {(readlink)} {(-f)} {(DQ ($ VSub_Name '$obj'))} ) ] ) left_token: <Left_CommandSub '$('> spids: [227 237] ) ) } ) ] ) left_token: <Left_CommandSub '$('> spids: [216 240] ) ) } spids: [214] ) ] spids: [214] ) (Sentence child: (AndOr ops: [Op_DPipe] children: [ (Subshell child: (AndOr ops: [Op_DAmp Op_DAmp Op_DAmp] children: [ (C {(echo_then_sudo)} {(objcopy)} {(--remove-section)} {(.gnu_debuglink)} {(DQ ($ VSub_Name '$obj'))} {(DQ ($ VSub_Name '$tmpfile'))} ) (C {(echo_then_sudo)} {(chown)} {(DQ ($ VSub_Name '$saved_ug'))} {(DQ ($ VSub_Name '$tmpfile'))} ) (C {(echo_then_sudo)} {(chmod)} {(DQ ($ VSub_Name '$saved_mode'))} {(DQ ($ VSub_Name '$tmpfile'))} ) (C {(echo_then_sudo)} {(mv)} {(DQ ($ VSub_Name '$tmpfile'))} {(DQ ($ VSub_Name '$obj'))} ) ] ) spids: [244 309] ) (SimpleCommand words: [{(echo)} {(DQ ('objcopy failed'))}] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [321] ) ] ) ] ) terminator: <Op_Semi ';'> ) (ControlFlow token: <ControlFlow_Return return> arg_word: {(1)} ) ] spids: [16777215 155] ) ] spids: [16777215 330] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:tmpfile) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children:[(C {(mktemp)})]) left_token: <Left_CommandSub '$('> spids: [343 345] ) ) } spids: [341] ) ] spids: [341] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:saved_ug) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (C {(stat)} {(-c)} {(DQ ('%u:%g'))} { (DQ (CommandSubPart command_list: (CommandList children: [ (C {(readlink)} {(-f)} {(DQ ($ VSub_Name '$obj'))}) ] ) left_token: <Left_CommandSub '$('> spids: [362 372] ) ) } ) ] ) left_token: <Left_CommandSub '$('> spids: [351 375] ) ) } spids: [349] ) ] spids: [349] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:saved_mode) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (C {(stat)} {(-c)} {(DQ ('%a'))} { (DQ (CommandSubPart command_list: (CommandList children: [ (C {(readlink)} {(-f)} {(DQ ($ VSub_Name '$obj'))}) ] ) left_token: <Left_CommandSub '$('> spids: [392 402] ) ) } ) ] ) left_token: <Left_CommandSub '$('> spids: [381 405] ) ) } spids: [379] ) ] spids: [379] ) (AndOr ops: [Op_DAmp Op_DAmp Op_DAmp Op_DAmp Op_DAmp Op_DPipe] children: [ (C {(echo_then_sudo)} {(objcopy)} {(--add-gnu-debuglink) (Lit_Other '=') (DQ ($ VSub_Name '$debuglink'))} {(DQ ($ VSub_Name '$obj'))} {(DQ ($ VSub_Name '$tmpfile'))} ) (C {(echo_then_sudo)} {(chown)} {(DQ ($ VSub_Name '$saved_ug'))} {(DQ ($ VSub_Name '$tmpfile'))} ) (C {(echo_then_sudo)} {(chmod)} {(DQ ($ VSub_Name '$saved_mode'))} {(DQ ($ VSub_Name '$tmpfile'))} ) (C {(echo_then_sudo)} {(mv)} {(DQ ($ VSub_Name '$tmpfile'))} {(DQ ($ VSub_Name '$obj'))} ) (SimpleCommand words: [{(echo)} {(DQ (success))}] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[485])] ) (ControlFlow token:<ControlFlow_Return return> arg_word:{(0)}) (Subshell child: (CommandList children: [ (Sentence child: (SimpleCommand words: [{(echo)} {(DQ ('objcopy failed'))}] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [505] ) ] ) terminator: <Op_Semi ';'> ) (ControlFlow token: <ControlFlow_Return return> arg_word: {(1)} ) ] ) spids: [498 512] ) ] ) ] spids: [139 515] ) ] spids: [45] ) spids: [40 44] ) (FuncDef name: contains_debug_symbols body: (BraceGroup children: [ (Pipeline children: [ (C {(objdump)} {(-h)} {(DQ ($ VSub_Number '$1'))}) (SimpleCommand words: [{(grep)} {(SQ <'\\.debug_info'>)}] redirects: [ (Redir op_id: Redir_Great fd: 1 arg_word: {(/dev/null)} spids: [544] ) (Redir op_id: Redir_Great fd: 2 arg_word: {(/dev/null)} spids: [547] ) ] ) ] negated: F ) ] spids: [525] ) spids: [520 524] ) (FuncDef name: read_debuglink body: (BraceGroup children: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:debuglink_info) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(objdump)} {(-h)} {(DQ ($ VSub_Number '$1'))}) (C {(grep)} {(SQ <'\\.gnu_debuglink'>)}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [563 581] ) ) } spids: [561] ) ] spids: [561] ) (If arms: [ (if_arm cond: [ (Sentence child: (DBracket expr: (BoolUnary op_id: BoolUnary_z child: {(DQ ($ VSub_Name '$debuglink_info'))} ) ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [{(echo)} {(DQ ('no debuglink in ') ($ VSub_Number '$1'))}] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[608])] ) (ControlFlow token:<ControlFlow_Return return> arg_word:{(1)}) ] spids: [16777215 598] ) ] spids: [16777215 617] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:debuglink_off) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(echo)} {(DQ ($ VSub_Name '$debuglink_info'))}) (C {(sed)} {(SQ <'s/^[[:blank:]]*//'>)}) (C {(tr)} {(-s)} {(SQ <'[:blank:]'>)} {(SQ <'\\t'>)}) (C {(cut)} {(-f6)}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [622 658] ) ) } spids: [620] ) ] spids: [620] ) (SimpleCommand words: [{(echo)} {(DQ ('read debuglink_off: ') ($ VSub_Name '$debuglink_off'))}] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[669])] ) (If arms: [ (if_arm cond: [ (Sentence child: (DBracket expr: (BoolUnary op_id: BoolUnary_n child: {(DQ ($ VSub_Name '$debuglink_off'))} ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:debuglink_off_bytes) op: Equal rhs: { (ArithSubPart anode: (ArithBinary op_id: Arith_Plus left: (ArithWord w: {(Lit_Digits 0) (Lit_ArithVarLike x) ($ VSub_Name '$debuglink_off') } ) right: (ArithWord w:{(Lit_Digits 0)}) ) spids: [690 701] ) } spids: [689] ) ] spids: [689] ) (If arms: [ (if_arm cond: [ (Sentence child: (DBracket expr: (BoolUnary op_id: BoolUnary_z child: {(DQ ($ VSub_Name '$debuglink_off_bytes'))} ) ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [{(echo)} {(DQ ('bad debuglink header'))}] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [726] ) ] ) (ControlFlow token: <ControlFlow_Return return> arg_word: {(1)} ) ] spids: [16777215 717] ) ] else_action: [ (Pipeline children: [ (C {(od)} {(--skip-bytes) (Lit_Other '=') (${ VSub_Name debuglink_off_bytes)} {(--string)} {(DQ ($ VSub_Number '$1'))} ) (C {(head)} {(-n1)}) (C {(sed)} {(SQ <'s/^[0-9a-f]* //'>)}) ] negated: F ) (ControlFlow token: <ControlFlow_Return return> arg_word: {(0)} ) ] spids: [736 773] ) ] spids: [16777215 686] ) ] spids: [16777215 776] ) (ControlFlow token:<ControlFlow_Return return> arg_word:{(1)}) ] spids: [558] ) spids: [553 557] ) (FuncDef name: find_debug_file_for body: (BraceGroup children: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:file) op: Equal rhs: {(DQ ($ VSub_Number '$1'))} spids: [794] ) ] spids: [794] ) (If arms: [ (if_arm cond: [ (Sentence child: (Pipeline children: [ (C {(readelf)} {(-wi)} {(DQ ($ VSub_Name '$file'))}) (SimpleCommand words: [{(grep)} {(-m1)} {(.)}] redirects: [ (Redir op_id: Redir_Great fd: 16777215 arg_word: {(/dev/null)} spids: [824] ) ] ) ] negated: T ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:debuglink_val) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [(C {(read_debuglink)} {(DQ ($ VSub_Name '$file'))})] ) left_token: <Left_CommandSub '$('> spids: [833 841] ) ) } spids: [831] ) ] spids: [831] ) (If arms: [ (if_arm cond: [ (Sentence child: (DBracket expr: (BoolUnary op_id: BoolUnary_n child: {(DQ ($ VSub_Name '$debuglink_val'))} ) ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [ {(echo)} {(DQ ('Read debuglink val: ') ($ VSub_Name '$debuglink_val'))} ] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [868] ) ] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:resolved_debuglink) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (C {(resolve_debuglink)} {(DQ ($ VSub_Name '$file'))} {(DQ ($ VSub_Name '$debuglink_val'))} ) ] ) left_token: <Left_CommandSub '$('> spids: [874 886] ) ) } spids: [872] ) ] spids: [872] ) (SimpleCommand words: [ {(echo)} { (DQ ('Resolved debuglink to: ') ($ VSub_Name '$resolved_debuglink')) } ] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [897] ) ] ) (C {(echo)} {(DQ ($ VSub_Name '$resolved_debuglink'))}) ] spids: [16777215 858] ) ] else_action: [ (SimpleCommand words: [{(echo)} {(DQ ('No debuglink found'))}] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[917])] ) (C {(echo)} {(DQ ($ VSub_Name '$file'))}) ] spids: [908 928] ) ] spids: [16777215 828] ) ] else_action: [(C {(echo)} {(DQ ($ VSub_Name '$file'))})] spids: [931 941] ) ] spids: [791] ) spids: [786 790] ) (FuncDef name: readelf_debug body: (BraceGroup children: [ (Assignment keyword: Assign_Declare flags: [-a] pairs: [(assign_pair lhs:(LhsName name:args) op:Equal spids:[958])] spids: [954] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:ctr) op:Equal rhs:{(1)} spids:[961])] spids: [961] ) (While cond: [(Sentence child:(C {(true)}) terminator:<Op_Semi ';'>)] body: (DoGroup children: [ (C {(args) (Lit_Other '[') ($ VSub_Name '$ctr') (Lit_Other ']') (Lit_Other '=') ($ VSub_Number '$1') } ) (Sentence child: (AndOr ops: [Op_DPipe] children: [(C {(shift)}) (ControlFlow token:<ControlFlow_Break break>)] ) terminator: <Op_Semi ';'> ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:ctr) op: Equal rhs: { (ArithSubPart anode: (ArithBinary op_id: Arith_Plus left: (ArithWord w:{($ VSub_Name '$ctr')}) right: (ArithWord w:{(Lit_Digits 1)}) ) spids: [990 999] ) } spids: [989] ) ] spids: [989] ) ] spids: [970 1002] ) ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:file) op: Equal rhs: { (BracedVarSub token: <VSub_Name args> bracket_op: (ArrayIndex expr: (ArithWord w: { (ArithSubPart anode: (ArithBinary op_id: Arith_Minus left: (ArithWord w:{($ VSub_Name '$ctr')}) right: (ArithWord w:{(Lit_Digits 1)}) ) spids: [1009 1018] ) } ) ) spids: [1006 1020] ) } spids: [1005] ) ] spids: [1005] ) (SimpleCommand words: [ {(echo)} { (DQ ('Slurped args: ') (BracedVarSub token: <VSub_Name args> bracket_op: (WholeArray op_id:Lit_At) spids: [1027 1032] ) ) } ] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[1035])] ) (SimpleCommand words: [{(echo)} {(DQ ('Guessed file arg: ') ($ VSub_Name '$file'))}] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[1046])] ) (C {(unset)} {(args) (Lit_Other '[') (ArithSubPart anode: (ArithBinary op_id: Arith_Minus left: (ArithWord w:{($ VSub_Name '$ctr')}) right: (ArithWord w:{(Lit_Digits 1)}) ) spids: [1054 1063] ) (Lit_Other ']') } ) (C {(readelf)} { (BracedVarSub token: <VSub_Name args> bracket_op: (WholeArray op_id:Lit_At) spids: [1069 1074] ) } { (DQ (CommandSubPart command_list: (CommandList children: [(C {(find_debug_file_for)} {(DQ ($ VSub_Name '$file'))})] ) left_token: <Left_CommandSub '$('> spids: [1077 1085] ) ) } ) ] spids: [951] ) spids: [946 950] ) (FuncDef name: get_cu_info body: (BraceGroup children: [ (Pipeline children: [ (C {(readelf_debug)} {(-wi)} {(DQ ($ VSub_Number '$1'))}) (C {(grep)} {(-A7)} {(SQ <DW_TAG_compile_unit>)}) (C {(tr)} {(SQ <'\\n'>)} {(SQ <'\\f'>)}) (C {(sed)} {(SQ <'s/\\f--\\f/\\n/g'>)}) ] negated: F ) ] spids: [1096] ) spids: [1091 1095] ) (FuncDef name: read_cu_info body: (BraceGroup children: [ (C {(read)} {(cu_info)}) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:ret) op: Equal rhs: {($ VSub_QMark '$?')} spids: [1153] ) ] spids: [1153] ) (If arms: [ (if_arm cond: [ (Sentence child: (DBracket expr: (BoolUnary op_id:BoolUnary_n child:{(DQ ($ VSub_Name '$cu_info'))}) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:cu_fname) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(echo)} {(DQ ($ VSub_Name '$cu_info'))}) (C {(tr)} {(SQ <'\\f'>)} {(SQ <'\\n'>)}) (C {(grep)} {(DW_AT_name)}) (C {(head)} {(-n1)}) (C {(sed)} { (SQ < 's/.*DW_AT_name[[:blank:]]*:[[:blank:]]*\\((.*, offset: 0x[0-9a-f]*): \\)\\?\\(.*\\)/\\2/' > ) } ) (C {(sed)} {(SQ <'s/[[:blank:]]*$//'>)}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [1175 1222] ) ) } spids: [1173] ) ] spids: [1173] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:cu_language_fullstr) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(echo)} {(DQ ($ VSub_Name '$cu_info'))}) (C {(tr)} {(SQ <'\\f'>)} {(SQ <'\\n'>)}) (C {(grep)} {(DW_AT_language)}) (C {(head)} {(-n1)}) (C {(sed)} { (SQ <'s/.*DW_AT_language[[:blank:]]*:[[:blank:]]*//'>) } ) (C {(sed)} {(SQ <'s/[[:blank:]]*$//'>)}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [1228 1275] ) ) } spids: [1226] ) ] spids: [1226] ) (SimpleCommand words: [{(echo)} {(DQ ('Note: found CU ') ($ VSub_Name '$cu_fname'))}] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[1286])] ) (SimpleCommand words: [{(echo)} {(DQ ('CU info is: ') ($ VSub_Name '$cu_info'))}] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[1297])] ) (SimpleCommand words: [ {(echo)} { (DQ ('language field of CU info is ') (CommandSubPart command_list: (CommandList children: [(C {(echo)} {(DQ ($ VSub_Name '$cu_language_fullstr'))})] ) left_token: <Left_CommandSub '$('> spids: [1305 1313] ) ) } ] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[1316])] ) (SimpleCommand words: [ {(echo)} { (DQ ('comp_dir line of CU info is ') (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(echo)} {(DQ ($ VSub_Name '$cu_info'))}) (C {(tr)} {(SQ <'\\f'>)} {(SQ <'\\n'>)}) (C {(grep)} {(DW_AT_comp_dir)}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [1324 1350] ) ) } ] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[1353])] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:cu_compdir) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(echo)} {(DQ ($ VSub_Name '$cu_info'))}) (C {(tr)} {(SQ <'\\f'>)} {(SQ <'\\n'>)}) (C {(grep)} {(DW_AT_comp_dir)}) (C {(sed)} { (SQ < 's/.*DW_AT_comp_dir[[:blank:]]*:[[:blank:]]*\\((.*, offset: 0x[0-9a-f]*): \\)\\?\\(.*\\)/\\2/' > ) } ) (C {(sed)} {(SQ <'s/[[:blank:]]*$//'>)}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [1359 1401] ) ) } spids: [1357] ) ] spids: [1357] ) (SimpleCommand words: [{(echo)} {(DQ ('Note: found comp_dir ') ($ VSub_Name '$cu_compdir'))}] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[1412])] ) (Case to_match: {(DQ ($ VSub_Name '$cu_fname'))} arms: [ (case_arm pat_list: [{(/) (Lit_Other '*')}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:cu_sourcepath) op: Equal rhs: {(DQ (${ VSub_Name cu_fname))} spids: [1435] ) ] spids: [1435] ) ] spids: [1429 1432 1443 16777215] ) (case_arm pat_list: [{(Lit_Other '*')}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:cu_sourcepath) op: Equal rhs: {(DQ (${ VSub_Name cu_compdir) (/) (${ VSub_Name cu_fname))} spids: [1451] ) ] spids: [1451] ) ] spids: [1446 1448 1463 16777215] ) ] spids: [1420 1426 1466] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:cu_language_num) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(echo)} {(DQ ($ VSub_Name '$cu_language_fullstr'))}) (C {(tr)} {(-s)} {(SQ <'[[:blank:]]'>)} {(SQ <'\\t'>)}) (C {(cut)} {(-f1)}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [1471 1499] ) ) } spids: [1469] ) ] spids: [1469] ) ] spids: [16777215 1170] ) ] else_action: [ (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:cu_fname) op:Equal rhs:{(DQ )} spids:[1506])] spids: [1506] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:cu_language_fullstr) op: Equal rhs: {(DQ )} spids: [1511] ) ] spids: [1511] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:cu_compdir) op: Equal rhs: {(DQ )} spids: [1516] ) ] spids: [1516] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:cu_sourcepath) op: Equal rhs: {(DQ )} spids: [1521] ) ] spids: [1521] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:cu_language_num) op: Equal rhs: {(DQ )} spids: [1526] ) ] spids: [1526] ) ] spids: [1503 1531] ) (If arms: [ (if_arm cond: [ (Sentence child: (DBracket expr: (BoolBinary op_id: BoolBinary_eq left: {($ VSub_Name '$ret')} right: {(0)} ) ) terminator: <Op_Semi ';'> ) ] action: [(Sentence child:(C {(true)}) terminator:<Op_Semi ';'>)] spids: [16777215 1548] ) ] else_action: [(Sentence child:(C {(false)}) terminator:<Op_Semi ';'>)] spids: [1553 1558] ) ] spids: [1145] ) spids: [1140 1144] ) (FuncDef name: resolve_debuglink body: (BraceGroup children: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:obj) op: Equal rhs: {(DQ ($ VSub_Number '$1'))} spids: [1571] ) ] spids: [1571] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:debuglink_value) op: Equal rhs: {(DQ ($ VSub_Number '$2'))} spids: [1577] ) ] spids: [1577] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:canon_obj_path) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [(C {(readlink)} {(-f)} {(DQ ($ VSub_Name '$obj'))})] ) left_token: <Left_CommandSub '$('> spids: [1587 1597] ) ) } spids: [1585] ) ] spids: [1585] ) (ForEach iter_name: candidate iter_words: [ { (DQ (CommandSubPart command_list: (CommandList children: [(C {(dirname)} {(DQ ($ VSub_Name '$canon_obj_path'))})] ) left_token: <Left_CommandSub '$('> spids: [1609 1617] ) (/.debug/) ($ VSub_Name '$debuglink_value') ) } {(/usr/lib/debug) (DQ (CommandSubPart command_list: (CommandList children: [(C {(dirname)} {(${ VSub_Name canon_obj_path)})] ) left_token: <Left_CommandSub '$('> spids: [1626 1634] ) ) (/) ($ VSub_Name '$debuglink_value') } {(/usr/lib/debug/.build-id/) (Lit_Other '*') (/) ($ VSub_Name '$debuglink_value')} ] do_arg_iter: F body: (DoGroup children: [ (If arms: [ (if_arm cond: [ (Sentence child: (C {(contains_debug_symbols)} {(DQ ($ VSub_Name '$candidate'))}) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [ {(echo)} { (DQ ('detected debug info within debuglink ') ($ VSub_Name '$debuglink_value') (' resolved at ') ($ VSub_Name '$candidate') ) } ] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [1671] ) ] ) (C {(echo)} {(DQ ($ VSub_Name '$candidate'))}) (ControlFlow token: <ControlFlow_Return return> arg_word: {(0)} ) ] spids: [16777215 1659] ) ] spids: [16777215 1687] ) ] spids: [1647 1690] ) spids: [1607 1645] ) (ControlFlow token:<ControlFlow_Return return> arg_word:{(1)}) ] spids: [1568] ) spids: [1563 1567] ) (FuncDef name: ensure_debug_symbols body: (BraceGroup children: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:obj) op: Equal rhs: {(DQ ($ VSub_Number '$1'))} spids: [1710] ) ] spids: [1710] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(contains_debug_symbols)} {(DQ ($ VSub_Name '$obj'))}) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [{(echo)} {(DQ ('detected debug info within file ') ($ VSub_Name '$obj'))}] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[1740])] ) (C {(echo)} {(DQ ($ VSub_Number '$1'))}) (ControlFlow token:<ControlFlow_Return return> arg_word:{(0)}) ] spids: [16777215 1729] ) ] spids: [16777215 1756] ) (If arms: [ (if_arm cond: [ (Sentence child: (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:debuglink_value) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [(C {(read_debuglink)} {(DQ ($ VSub_Name '$obj'))})] ) left_token: <Left_CommandSub '$('> spids: [1769 1777] ) ) } spids: [1767] ) ] spids: [1767] ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:resolved_debuglink) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (C {(resolve_debuglink)} {(DQ ($ VSub_Name '$obj'))} {(DQ ($ VSub_Name '$debuglink_value'))} ) ] ) left_token: <Left_CommandSub '$('> spids: [1786 1798] ) ) } spids: [1784] ) ] spids: [1784] ) (If arms: [ (if_arm cond: [ (Sentence child: (AndOr ops: [Op_DAmp] children: [ (DBracket expr: (BoolUnary op_id: BoolUnary_n child: {(DQ ($ VSub_Name '$resolved_debuglink'))} ) ) (C {(contains_debug_symbols)} {(DQ ($ VSub_Name '$resolved_debuglink'))} ) ] ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [ {(echo)} { (DQ ('detected debug info within debuglink ') ($ VSub_Name '$debuglink_value') (' resolved at ') ($ VSub_Name '$candidate') ) } ] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [1835] ) ] ) (C {(echo)} {(DQ ($ VSub_Name '$candidate'))}) (ControlFlow token: <ControlFlow_Return return> arg_word: {(0)} ) ] spids: [16777215 1823] ) ] spids: [16777215 1851] ) ] spids: [16777215 1781] ) ] spids: [16777215 1858] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:success_attempt) op: Equal rhs: {(DQ )} spids: [2012] ) ] spids: [2012] ) (ForEach iter_name: attempt iter_words: [ {(/usr/lib/debug) (DQ (CommandSubPart command_list: (CommandList children: [(C {(readlink)} {(-f)} {(DQ ($ VSub_Name '$obj'))})] ) left_token: <Left_CommandSub '$('> spids: [2031 2041] ) ) } {(/usr/lib/debug) (DQ (CommandSubPart command_list: (CommandList children: [ (C {(dirname)} { (DQ (CommandSubPart command_list: (CommandList children: [(C {(readlink)} {(-f)} {(DQ ($ VSub_Name '$obj'))})] ) left_token: <Left_CommandSub '$('> spids: [2053 2063] ) ) } ) ] ) left_token: <Left_CommandSub '$('> spids: [2048 2066] ) (/) (CommandSubPart command_list: (CommandList children: [(C {(basename)} {(DQ ($ VSub_Name '$obj'))})] ) left_token: <Left_CommandSub '$('> spids: [2068 2076] ) ) } ] do_arg_iter: F body: (DoGroup children: [ (SimpleCommand words: [ {(echo)} {(DQ ('looking for a package containing ') ($ VSub_Name '$attempt'))} ] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[2092])] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:apt_found) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(echo_then_sudo)} {(apt-file)} {(-F)} {(find)} {(DQ ($ VSub_Name '$attempt'))} ) (C {(sed)} {(SQ <'s^: /.*^^'>)}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [2098 2120] ) ) } spids: [2096] ) ] spids: [2096] ) (If arms: [ (if_arm cond: [ (Sentence child: (DBracket expr: (BoolUnary op_id: BoolUnary_n child: {(DQ ($ VSub_Name '$apt_found'))} ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:pkg) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(echo)} {(DQ ($ VSub_Name '$apt_found'))}) (C {(cut)} {(-f1)}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [2142 2156] ) ) } spids: [2140] ) ] spids: [2140] ) (SimpleCommand words: [{(echo)} {(DQ ('found ') ($ VSub_Name '$pkg'))}] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [2167] ) ] ) (If arms: [ (if_arm cond: [ (Sentence child: (DBracket expr: (BoolUnary op_id: BoolUnary_n child: {(DQ ($ VSub_Name '$pkg'))} ) ) terminator: <Op_Semi ';'> ) ] action: [ (If arms: [ (if_arm cond: [ (Sentence child: (SimpleCommand words: [{(dpkg)} {(-p)} {(DQ ($ VSub_Name '$pkg'))}] redirects: [ (Redir op_id: Redir_Great fd: 16777215 arg_word: {(/dev/null)} spids: [2197] ) (Redir op_id: Redir_Great fd: 2 arg_word: {(/dev/null)} spids: [2200] ) ] ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [ {(echo)} {(DQ ($ VSub_Name '$pkg') (' is already installed'))} ] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [2214] ) ] ) ] spids: [16777215 2204] ) ] else_action: [ (SimpleCommand words: [ {(echo)} {(DQ ('Attempting install of ') ($ VSub_Name '$pkg'))} ] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [2228] ) ] ) (If arms: [ (if_arm cond: [ (Sentence child: (Pipeline children: [ (C {(echo_then_sudo)} {(apt-get)} {(install)} {(DQ ($ VSub_Name '$pkg'))} ) ] negated: T ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [{(echo)} {(DQ ('install failed'))}] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [2256] ) ] ) (ControlFlow token: <ControlFlow_Return return> arg_word: {(1)} ) ] spids: [16777215 2247] ) ] spids: [16777215 2265] ) ] spids: [2218 2272] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(contains_debug_symbols)} {(DQ ($ VSub_Name '$attempt'))} ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:correct_debuglink) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (C {(basename)} { (DQ (CommandSubPart command_list: (CommandList children: [ (C {(readlink)} {(-f)} { (DQ ($ VSub_Name '$attempt' ) ) } ) ] ) left_token: <Left_CommandSub '$('> spids: [2298 2308] ) ) } ) ] ) left_token: <Left_CommandSub '$('> spids: [2293 2311] ) ) } spids: [2291] ) ] spids: [2291] ) (SimpleCommand words: [ {(echo)} { (DQ ('debuglink should say ') ($ VSub_Name '$correct_debuglink') ) } ] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [2322] ) ] ) (If arms: [ (if_arm cond: [ (Sentence child: (Pipeline children: [ (C {(fixup_debuglink)} {(DQ ($ VSub_Name '$obj'))} {(DQ ($ VSub_Name '$attempt'))} ) ] negated: T ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [{(echo)} {(DQ (failed))}] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [2350] ) ] ) (ControlFlow token: <ControlFlow_Return return> arg_word: {(1)} ) ] spids: [16777215 2341] ) ] spids: [16777215 2360] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:verify_debuglink) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (C {(read_debuglink)} {(DQ ($ VSub_Name '$obj'))} ) ] ) left_token: <Left_CommandSub '$('> spids: [2369 2377] ) ) } spids: [2367] ) ] spids: [2367] ) (If arms: [ (if_arm cond: [ (Sentence child: (DBracket expr: (BoolBinary op_id: BoolBinary_GlobDEqual left: { (DQ ($ VSub_Name '$verify_debuglink') ) } right: { (DQ ($ VSub_Name '$correct_debuglink') ) } ) ) terminator: <Op_Semi ';'> ) ] action: [ (C {(echo)} {(DQ ($ VSub_Name '$attempt'))}) (ControlFlow token: <ControlFlow_Return return> arg_word: {(0)} ) ] spids: [16777215 2398] ) ] else_action: [ (SimpleCommand words: [ {(echo)} {(DQ ('debuglink not fixed up properly'))} ] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [2423] ) ] ) (ControlFlow token: <ControlFlow_Return return> arg_word: {(1)} ) ] spids: [2414 2432] ) ] spids: [16777215 2284] ) ] else_action: [ (SimpleCommand words: [ {(echo)} { (DQ ( 'installed package unexpectedly lacked debug info' ) ) } ] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [2445] ) ] ) (ControlFlow token: <ControlFlow_Return return> arg_word: {(1)} ) ] spids: [2435 2454] ) ] spids: [16777215 2184] ) ] else_action: [ (SimpleCommand words: [{(echo)} {(DQ ('apt-file printed something strange'))}] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [2469] ) ] ) (ControlFlow token: <ControlFlow_Continue continue> ) ] spids: [2457 2476] ) ] spids: [16777215 2137] ) ] else_action: [ (SimpleCommand words: [{(echo)} {(DQ ('package not found'))}] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[2492])] ) (ControlFlow token:<ControlFlow_Continue continue>) ] spids: [2479 2499] ) ] spids: [2081 2502] ) spids: [2026 2079] ) (SimpleCommand words: [{(echo)} {(DQ ('giving up'))}] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[2517])] ) (ControlFlow token:<ControlFlow_Return return> arg_word:{(1)}) ] spids: [1707] ) spids: [1702 1706] ) (FuncDef name: ensure_debug_source body: (BraceGroup children: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:obj) op: Equal rhs: {(DQ ($ VSub_Number '$1'))} spids: [2536] ) ] spids: [2536] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:first_compile_unit_context) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(readelf)} {(-wi)} {(DQ ($ VSub_Name '$obj'))}) (C {(grep)} {(-m1)} {(-A5)} {(compile_unit)}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [2548 2568] ) ) } spids: [2546] ) ] spids: [2546] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:compile_unit_name) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(echo)} {(DQ ($ VSub_Name '$first_compile_unit_context'))}) (C {(grep)} {(DW_AT_name)}) (C {(sed)} { (SQ < 's/.*DW_AT_name.*indirect string, offset: 0x[0-9a-f]\\+): //' > ) } ) (C {(sed)} {(SQ <'s/[[:blank:]]*$//'>)}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [2577 2609] ) ) } spids: [2575] ) ] spids: [2575] ) (SimpleCommand words: [{(echo)} {(DQ ('extracted CU name: ') ($ VSub_Name '$compile_unit_name'))}] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[2633])] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:comp_dir) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(echo)} {(DQ ($ VSub_Name '$first_compile_unit_context'))}) (C {(grep)} {(comp_dir)}) (C {(sed)} { (SQ < 's/.*DW_AT_comp_dir.*(indirect string, offset: 0x[0-9a-f]\\+): //' > ) } ) (C {(sed)} {(SQ <'s/[[:blank:]]*$//'>)}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [2639 2671] ) ) } spids: [2637] ) ] spids: [2637] ) (SimpleCommand words: [{(echo)} {(DQ ('extracted compilation directory: ') ($ VSub_Name '$comp_dir'))}] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[2685])] ) (If arms: [ (if_arm cond: [ (Sentence child: (DBracket expr: (BoolUnary op_id: BoolUnary_r child: {(DQ (${ VSub_Name comp_dir) (/) (${ VSub_Name compile_unit_name))} ) ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [{(echo)} {(DQ ('guessing that source does exist already'))}] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[2723])] ) (ControlFlow token:<ControlFlow_Return return> arg_word:{(0)}) ] spids: [16777215 2714] ) ] else_action: [ (SimpleCommand words: [{(echo)} {(DQ ('source does not exist already'))}] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[2741])] ) ] spids: [2732 2745] ) (If arms: [ (if_arm cond: [ (Sentence child: (DBracket expr: (BoolUnary op_id: BoolUnary_z child: {(DQ ($ VSub_Name '$DPKG_SOURCE_ROOT'))} ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:DPKG_SOURCE_ROOT) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children:[(C {(mktemp)} {(-d)})]) left_token: <Left_CommandSub '$('> spids: [2772 2778] ) ) } spids: [2770] ) ] spids: [2770] ) ] spids: [16777215 2767] ) ] spids: [16777215 2782] ) (SimpleCommand words: [{(echo)} {(DQ ('downloading source to ') ($ VSub_Name '$DPKG_SOURCE_ROOT'))}] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[2792])] ) (Subshell child: (CommandList children: [ (C {(cd)} {(DQ ($ VSub_Name '$DPKG_SOURCE_ROOT'))}) (AndOr ops: [Op_DPipe] children: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:owning_package) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(dpkg)} {(-S)} {(DQ ($ VSub_Name '$obj'))}) (C {(sed)} {(SQ <'s^: /.*^^'>)}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [2811 2829] ) ) } spids: [2809] ) ] spids: [2809] ) (Subshell child: (CommandList children: [ (Sentence child: (SimpleCommand words: [{(echo)} {(DQ ('failed to identify owning package'))}] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [2841] ) ] ) terminator: <Op_Semi ';'> ) (ControlFlow token: <ControlFlow_Return return> arg_word: {(1)} ) ] ) spids: [2834 2848] ) ] ) (AndOr ops: [Op_DPipe] children: [ (C {(apt-get)} {(source)} {(DQ ($ VSub_Name '$owning_package'))}) (Subshell child: (CommandList children: [ (Sentence child: (SimpleCommand words: [{(echo)} {(DQ ('failed to download source'))}] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [2868] ) ] ) terminator: <Op_Semi ';'> ) (ControlFlow token: <ControlFlow_Return return> arg_word: {(1)} ) ] ) spids: [2861 2875] ) ] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:source_dirname) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [(C {(ls)} {(-t)}) (C {(head)} {(-n1)})] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [2880 2892] ) ) } spids: [2878] ) ] spids: [2878] ) (SimpleCommand words: [ {(echo)} {(DQ ('guessing source was extracted in ') ($ VSub_Name '$source_dirname'))} ] redirects: [(Redir op_id:Redir_GreatAnd fd:1 arg_word:{(2)} spids:[2903])] ) (Case to_match: {(DQ ($ VSub_Name '$comp_dir'))} arms: [ (case_arm pat_list: [{(/build/buildd/) (Lit_Other '*')}] action: [ (SimpleCommand words: [{(echo)} {(DQ ('found a buildd build'))}] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [2933] ) ] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:source_dirname_escaped) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(echo)} {(DQ ($ VSub_Name '$source_dirname'))}) (C {(escape_regexp_floating)}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [2939 2951] ) ) } spids: [2937] ) ] spids: [2937] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:prefix) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(echo)} {(DQ ($ VSub_Name '$comp_dir'))}) (C {(sed)} { (DQ ('s^') (Lit_Other '\\') ('(.*/') (${ VSub_Name source_dirname_escaped) (/) (Lit_Other '\\') (').*^') (Lit_Other '\\') ('1^') ) } ) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [2960 2986] ) ) } spids: [2958] ) ] spids: [2958] ) (SimpleCommand words: [ {(echo)} {(DQ ('calculated source path prefix ') ($ VSub_Name '$prefix'))} ] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [2997] ) ] ) (AndOr ops: [Op_DAmp Op_DPipe] children: [ (C {(echo_then_sudo)} {(mkdir)} {(-p)} { (DQ (CommandSubPart command_list: (CommandList children: [(C {(dirname)} {(DQ ($ VSub_Name '$prefix'))})] ) left_token: <Left_CommandSub '$('> spids: [3012 3020] ) ) } ) (C {(echo_then_sudo)} {(ln)} {(-s)} {(DQ ($ VSub_Name '$source_dirname'))} {(DQ ($ VSub_Name '$prefix'))} ) (Subshell child: (CommandList children: [ (Sentence child: (SimpleCommand words: [{(echo)} {(DQ ('failed to mkdir or symlink'))}] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [3053] ) ] ) terminator: <Op_Semi ';'> ) (ControlFlow token: <ControlFlow_Return return> arg_word: {(1)} ) ] ) spids: [3045 3060] ) ] ) (SimpleCommand words: [{(echo)} {(DQ (success))}] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [3069] ) ] ) (ControlFlow token: <ControlFlow_Return return> arg_word: {(0)} ) ] spids: [2921 2924 3078 16777215] ) (case_arm pat_list: [{(Lit_Other '*')}] action: [ (SimpleCommand words: [{(echo)} {(DQ ('package was built at bad source directory'))}] redirects: [ (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [3092] ) ] ) (ControlFlow token: <ControlFlow_Return return> arg_word: {(1)} ) ] spids: [3081 3083 3102 16777215] ) ] spids: [2912 2918 3105] ) ] ) spids: [2798 3108] ) ] spids: [2533] ) spids: [2528 2532] ) ] )