(command.CommandList children: [ (C {(Id.KW_Set set)} {(-o)} {(nounset)}) (C {(Id.KW_Set set)} {(-o)} {(pipefail)}) (C {(Id.KW_Set set)} {(-o)} {(errexit)}) (C {(source)} {(build/common.sh)}) (command.ShFunction name: write-release-date body: (command.BraceGroup children: [ (C {(mkdir)} {(-p)} {(_build)}) (command.Simple words: [{(date)} {(--utc)} {(--rfc-3339)} {(seconds)}] redirects: [ (redir.Redir op: (Token id:Id.Redir_Great val:'>' span_id:73) fd: -1 arg_word: {(_build/release-date.txt)} ) ] ) ] ) ) (command.ShFunction name: main-name body: (command.BraceGroup children: [ (C {(local)} {(Id.Lit_VarLike 'python_main=') (braced_var_sub token: (Token id:Id.VSub_Number val:1 span_id:91) suffix_op: (suffix_op.Unary op_id:Id.VTest_ColonHyphen arg_word:{(hello)}) ) } ) (C {(local)} {(Id.Lit_VarLike 'ovm_bundle_prefix=') (braced_var_sub token: (Token id:Id.VSub_Number val:2 span_id:101) suffix_op: (suffix_op.Unary op_id:Id.VTest_ColonHyphen arg_word:{(hello.ovm)}) ) } ) (command.Simple words: [{(cat)}] redirects: [ (redir.HereDoc op: (Token id:Id.Redir_DLess val:'<<' span_id:110) fd: -1 here_begin: {(EOF)} here_end_span_id: 136 stdin_parts: [ ('char* MAIN_NAME = ') (Id.Right_DoubleQuote '"') ($ Id.VSub_DollarName '$python_main') (Id.Right_DoubleQuote '"') (';\n') ('#if OVM_DEBUG\n') (' char* OVM_BUNDLE_FILENAME = ') (Id.Right_DoubleQuote '"') (${ Id.VSub_Name ovm_bundle_prefix) (-dbg) (Id.Right_DoubleQuote '"') (';\n') ('#else\n') (' char* OVM_BUNDLE_FILENAME = ') (Id.Right_DoubleQuote '"') ($ Id.VSub_DollarName '$ovm_bundle_prefix') (Id.Right_DoubleQuote '"') (';\n') ('#endif\n') ] ) ] ) ] ) ) (command.ShFunction name: c-module-toc body: (command.BraceGroup children: [(C {(cd)} {($ Id.VSub_DollarName '$PY27')}) (C {(../build/c_module_toc.py)})] ) ) (command.ShFunction name: runpy-deps body: (command.BraceGroup children: [ (C {($ Id.VSub_DollarName '$PREPARE_DIR') (/python)} {(-S)} {(build/runpy_deps.py)} {(both)} {(DQ ($ Id.VSub_At '$@'))} ) ] ) ) (command.ShFunction name: runpy-py-to-compile body: (command.BraceGroup children: [ (C {($ Id.VSub_DollarName '$PREPARE_DIR') (/python)} {(-S)} {(build/runpy_deps.py)} {(py)}) ] ) ) (command.ShFunction name: app-deps body: (command.BraceGroup children: [ (C {(local)} {(Id.Lit_VarLike 'app_name=') (braced_var_sub token: (Token id:Id.VSub_Number val:1 span_id:247) suffix_op: (suffix_op.Unary op_id:Id.VTest_ColonHyphen arg_word:{(hello)}) ) } ) (C {(local)} {(Id.Lit_VarLike 'pythonpath=') (braced_var_sub token: (Token id:Id.VSub_Number val:2 span_id:257) suffix_op: (suffix_op.Unary op_id: Id.VTest_ColonHyphen arg_word: {(build) (Id.Lit_Slash /) (testdata)} ) ) } ) (C {(local)} {(Id.Lit_VarLike 'main_module=') (braced_var_sub token: (Token id:Id.VSub_Number val:3 span_id:269) suffix_op: (suffix_op.Unary op_id:Id.VTest_ColonHyphen arg_word:{(hello)}) ) } ) (C {(local)} {(Id.Lit_VarLike 'prefix=') (_build/) ($ Id.VSub_DollarName '$app_name') (/app-deps)} ) (C {(ln)} {(-s)} {(-f)} {($ Id.VSub_DollarName '$PWD') (/build/app_deps.py)} {(_tmp)}) (command.Simple words: [ {($ Id.VSub_DollarName '$PREPARE_DIR') (/python)} {(-S)} {(_tmp/app_deps.py)} {(both)} {($ Id.VSub_DollarName '$main_module')} {($ Id.VSub_DollarName '$prefix')} ] more_env: [ (env_pair name: PYTHONPATH val: {($ Id.VSub_DollarName '$pythonpath')} spids: [302] ) ] ) ] ) ) (command.ShFunction name: py-to-compile body: (command.BraceGroup children: [ (C {(local)} {(Id.Lit_VarLike 'pythonpath=') (braced_var_sub token: (Token id:Id.VSub_Number val:1 span_id:337) suffix_op: (suffix_op.Unary op_id: Id.VTest_ColonHyphen arg_word: {(build) (Id.Lit_Slash /) (testdata)} ) ) } ) (C {(local)} {(Id.Lit_VarLike 'main_module=') (braced_var_sub token: (Token id:Id.VSub_Number val:2 span_id:349) suffix_op: (suffix_op.Unary op_id:Id.VTest_ColonHyphen arg_word:{(hello)}) ) } ) (command.Simple words: [ {($ Id.VSub_DollarName '$PREPARE_DIR') (/python)} {(-S)} {(build/app_deps.py)} {(py)} {($ Id.VSub_DollarName '$main_module')} ] more_env: [ (env_pair name: PYTHONPATH val: {($ Id.VSub_DollarName '$pythonpath')} spids: [356] ) ] ) ] ) ) (command.ShFunction name: quick-ref-manifest body: (command.BraceGroup children: [ (C {(local)} {(Id.Lit_VarLike 'dir=') ($ Id.VSub_Number '$1')}) (command.ForEach iter_name: path iter_words: [{($ Id.VSub_DollarName '$dir') (/) (Id.Lit_Star '*')}] do_arg_iter: F body: (command.DoGroup children: [ (C {(echo)} {(DQ ($ Id.VSub_DollarName '$path') (' ') ($ Id.VSub_DollarName '$path'))} ) ] ) ) ] ) ) (command.ShFunction name: pyc-version-manifest body: (command.BraceGroup children: [ (C {(local)} {(Id.Lit_VarLike 'manifest_path=') (braced_var_sub token: (Token id:Id.VSub_Number val:1 span_id:433) suffix_op: (suffix_op.Unary op_id: Id.VTest_ColonHyphen arg_word: {(_build) (Id.Lit_Slash /) (oil) (Id.Lit_Slash /) (bytecode-opy-manifest.txt)} ) ) } ) (C {(local)} {(Id.Lit_VarLike 'filename=') (command_sub left_token: (Token id:Id.Left_DollarParen val:'$(' span_id:458) command_list: (command.CommandList children: [(C {(basename)} {($ Id.VSub_DollarName '$manifest_path')})] ) ) } ) (C {(local)} {(Id.Lit_VarLike 'user_str=') (braced_var_sub token: (Token id:Id.VSub_Name val:filename span_id:470) suffix_op: (suffix_op.Unary op_id:Id.VOp1_Percent arg_word:{(-manifest.txt)}) ) (.zip) } ) (C {(local)} {(Id.Lit_VarLike 'dir=') (command_sub left_token: (Token id:Id.Left_DollarParen val:'$(' span_id:480) command_list: (command.CommandList children: [(C {(dirname)} {($ Id.VSub_DollarName '$manifest_path')})] ) ) } ) (command.Simple words: [{(echo)} {($ Id.VSub_DollarName '$user_str')}] redirects: [ (redir.Redir op: (Token id:Id.Redir_Great val:'>' span_id:492) fd: -1 arg_word: {($ Id.VSub_DollarName '$dir') (/pyc-version.txt)} ) ] ) (C {(echo)} {($ Id.VSub_DollarName '$dir') (/pyc-version.txt)} {(pyc-version.txt)}) ] ) ) (command.ShFunction name: make-dotd body: (command.BraceGroup children: [ (C {(local)} {(Id.Lit_VarLike 'app_name=') (braced_var_sub token: (Token id:Id.VSub_Number val:1 span_id:527) suffix_op: (suffix_op.Unary op_id:Id.VTest_ColonHyphen arg_word:{(hello)}) ) } ) (C {(local)} {(Id.Lit_VarLike 'app_deps_to_compile=') (braced_var_sub token: (Token id:Id.VSub_Number val:2 span_id:537) suffix_op: (suffix_op.Unary op_id: Id.VTest_ColonHyphen arg_word: {(_tmp) (Id.Lit_Slash /) (hello) (Id.Lit_Slash /) (app-deps-to-compile.txt)} ) ) } ) (C {(echo)} {(DQ ('# TODO ') ($ Id.VSub_DollarName '$app_deps_to_compile'))}) (C {(echo)} {(DQ (X_build/) ($ Id.VSub_DollarName '$app_name') ('/ovm:'))}) (C {(echo)} {(DQ (X_build/) ($ Id.VSub_DollarName '$app_name') ('/ovm-dbg:'))}) (C {(echo)} {(DQ (X_build/) ($ Id.VSub_DollarName '$app_name') ('/ovm-cov:'))}) ] ) ) (command.ShFunction name: extdecls body: (command.BraceGroup children: [ (command.ForEach iter_name: mod iter_words: [{(DQ ($ Id.VSub_At '$@'))}] do_arg_iter: F body: (command.DoGroup children: [ (command.AndOr ops: [Id.Op_DAmp] children: [ (C {(test)} {(DQ ($ Id.VSub_DollarName '$mod'))} {(Id.Lit_Equals '=')} {(readline)} ) (C {(echo)} {(DQ ('#ifdef HAVE_READLINE'))}) ] ) (C {(echo)} {(DQ ('extern void init') ($ Id.VSub_DollarName '$mod') ('(void);'))}) (command.AndOr ops: [Id.Op_DAmp] children: [ (C {(test)} {(DQ ($ Id.VSub_DollarName '$mod'))} {(Id.Lit_Equals '=')} {(readline)} ) (C {(echo)} {(DQ ('#endif'))}) ] ) ] ) ) (command.ControlFlow token: (Token id:Id.ControlFlow_Return val:return span_id:687) arg_word: {(0)} ) ] ) ) (command.ShFunction name: initbits body: (command.BraceGroup children: [ (command.ForEach iter_name: mod iter_words: [{(DQ ($ Id.VSub_At '$@'))}] do_arg_iter: F body: (command.DoGroup children: [ (command.AndOr ops: [Id.Op_DAmp] children: [ (C {(test)} {(DQ ($ Id.VSub_DollarName '$mod'))} {(Id.Lit_Equals '=')} {(readline)} ) (C {(echo)} {(DQ ('#ifdef HAVE_READLINE'))}) ] ) (C {(echo)} { (DQ (' {') (word_part.EscapedLiteral token: (Token id:Id.Lit_EscapedChar val:'\\"' span_id:741) ) ($ Id.VSub_DollarName '$mod') (word_part.EscapedLiteral token: (Token id:Id.Lit_EscapedChar val:'\\"' span_id:743) ) (', init') ($ Id.VSub_DollarName '$mod') ('},') ) } ) (command.AndOr ops: [Id.Op_DAmp] children: [ (C {(test)} {(DQ ($ Id.VSub_DollarName '$mod'))} {(Id.Lit_Equals '=')} {(readline)} ) (C {(echo)} {(DQ ('#endif'))}) ] ) ] ) ) (command.ControlFlow token: (Token id:Id.ControlFlow_Return val:return span_id:772) arg_word: {(0)} ) ] ) ) (command.ShFunction name: gen-module-init body: (command.BraceGroup children: [ (C {(local)} {(extdecls)}) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:extdecls) op: assign_op.Equal rhs: { (command_sub left_token: (Token id:Id.Left_DollarParen val:'$(' span_id:798) command_list: (command.CommandList children: [(C {(extdecls)} {(DQ ($ Id.VSub_At '$@'))})] ) ) } spids: [797] ) ] ) (C {(local)} {(initbits)}) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:initbits) op: assign_op.Equal rhs: { (command_sub left_token: (Token id:Id.Left_DollarParen val:'$(' span_id:813) command_list: (command.CommandList children: [(C {(initbits)} {(DQ ($ Id.VSub_At '$@'))})] ) ) } spids: [812] ) ] ) (C {(local)} {(Id.Lit_VarLike 'template=') ($ Id.VSub_DollarName '$PY27') (/Modules/config.c.in)} ) (C {(awk)} {(-v)} {(Id.Lit_VarLike 'template=') ($ Id.VSub_DollarName '$template')} {(-v)} {(Id.Lit_VarLike 'extdecls=') (DQ ($ Id.VSub_DollarName '$extdecls'))} {(-v)} {(Id.Lit_VarLike 'initbits=') (DQ ($ Id.VSub_DollarName '$initbits'))} { (SQ (Token id:Id.Lit_Chars val:'\n' span_id:853) (Token id:Id.Lit_Chars val:' BEGIN {\n' span_id:854) (Token id: Id.Lit_Chars val: ' print "/* Generated automatically from " template " */"\n' span_id: 855 ) (Token id:Id.Lit_Chars val:' }\n' span_id:856) (Token id:Id.Lit_Chars val:' /MARKER 1/ {\n' span_id:857) (Token id:Id.Lit_Chars val:' print extdecls\n' span_id:858) (Token id:Id.Lit_Chars val:' next\n' span_id:859) (Token id:Id.Lit_Chars val:' }\n' span_id:860) (Token id:Id.Lit_Chars val:' /MARKER 2/ {\n' span_id:861) (Token id:Id.Lit_Chars val:' print initbits\n' span_id:862) (Token id:Id.Lit_Chars val:' next\n' span_id:863) (Token id:Id.Lit_Chars val:' }\n' span_id:864) (Token id:Id.Lit_Chars val:' {\n' span_id:865) (Token id:Id.Lit_Chars val:' print $0\n' span_id:866) (Token id:Id.Lit_Chars val:' }\n' span_id:867) (Token id:Id.Lit_Chars val:' ' span_id:868) ) } {($ Id.VSub_DollarName '$template')} ) ] ) ) (command.ShFunction name: join-modules body: (command.BraceGroup children: [ (C {(local)} {(Id.Lit_VarLike 'static=') (braced_var_sub token: (Token id:Id.VSub_Number val:1 span_id:897) suffix_op: (suffix_op.Unary op_id: Id.VTest_ColonHyphen arg_word: {(static-c-modules.txt)} ) ) } ) (C {(local)} {(Id.Lit_VarLike 'discovered=') (braced_var_sub token: (Token id:Id.VSub_Number val:2 span_id:907) suffix_op: (suffix_op.Unary op_id: Id.VTest_ColonHyphen arg_word: {(_build) (Id.Lit_Slash /) (oil) (Id.Lit_Slash /) (all-deps-c.txt)} ) ) } ) (command.Pipeline children: [ (C {(egrep)} {(--no-filename)} {(--only-matching)} {(SQ (Token id:Id.Lit_Chars val:'^[a-zA-Z0-9_\\.]+' span_id:941))} {($ Id.VSub_DollarName '$static')} {($ Id.VSub_DollarName '$discovered')} ) (C {(sort)}) (C {(uniq)}) ] negated: F ) ] ) ) (command.ShFunction name: clean-pyc body: (command.BraceGroup children: [ (command.Pipeline children: [ (C {(find)} {(.)} { (word_part.EscapedLiteral token: (Token id:Id.Lit_EscapedChar val:'\\(' span_id:989) ) } {(-type)} {(d)} {(-a)} {(-name)} {(SQ (Token id:Id.Lit_Chars val:'_*' span_id:1000))} {(-a)} {(-prune)} { (word_part.EscapedLiteral token: (Token id:Id.Lit_EscapedChar val:'\\)' span_id:1007) ) } {(-o)} {(-name)} {(SQ (Token id:Id.Lit_Chars val:'*.pyc' span_id:1014))} {(-a)} {(-print)} ) (C {(xargs)} {(--no-run-if-empty)} {(--)} {(rm)} {(--verbose)}) ] negated: F ) ] ) ) (command.ShFunction name: clean-repo body: (command.BraceGroup children: [ (C {(clean-source-tarball-build)}) (C {(rm)} {(-r)} {(-f)} {(-v)} {(_build)} {(_release)}) (C {(rm)} {(-f)} {(-v)} {(_bin/hello.) (Id.Lit_Star '*')} {(_bin/opy.) (Id.Lit_Star '*')}) (C {(clean-pyc)}) ] ) ) (command.ShFunction name: clean-source-tarball-build body: (command.BraceGroup children: [ (C {(rm)} {(-f)} {(-v)} {(_bin/oil.) (Id.Lit_Star '*')}) (C {(rm)} {(-f)} {(-v)} {(_build/oil/ovm)} {(_build/oil/ovm-dbg)}) ] ) ) (C {(DQ ($ Id.VSub_At '$@'))}) ] )