Home
last modified time | relevance | path

Searched refs:outfp (Results 1 – 15 of 15) sorted by relevance

/third_party/python/Tools/freeze/
Dmakefreeze.py42 with bkfile.open(base + file, 'w') as outfp:
52 writecode(outfp, mangled, str)
55 with bkfile.open(base + 'frozen.c', 'w') as outfp:
57 outfp.write('extern unsigned char M_%s[];\n' % mangled)
58 outfp.write(header)
60 outfp.write('\t{"%s", M_%s, %d},\n' % (mod, mangled, size))
61 outfp.write('\n')
67 outfp.write('\t{"%s", NULL, 0},\n' % (mod,))
68 outfp.write(trailer)
69 outfp.write(entry_point)
[all …]
Dmakeconfig.py9 def makeconfig(infp, outfp, modules, with_ifdef=0): argument
13 outfp.write(line)
20 outfp.write("#ifndef PyInit_%s\n"%mod)
21 outfp.write('extern PyObject* PyInit_%s(void);\n' % mod)
23 outfp.write("#endif\n")
29 outfp.write('\t{"%s", PyInit_%s},\n' %
49 outfp = sys.stdout
51 outfp = open(sys.argv[2], 'w')
52 makeconfig(infp, outfp, sys.argv[3:])
53 if outfp != sys.stdout:
[all …]
Dmakemakefile.py5 def makemakefile(outfp, makevars, files, target): argument
6 outfp.write("# Makefile generated by freeze.py script\n\n")
10 outfp.write("%s=%s\n" % (key, makevars[key]))
11 outfp.write("\nall: %s\n\n" % target)
19 outfp.write("%s: %s\n" % (dest, file))
20 outfp.write("\t$(CC) $(PY_CFLAGS) $(PY_CPPFLAGS) -c %s\n" % file)
24 outfp.write("\n%s: %s\n" % (target, ' '.join(deps)))
25 outfp.write("\t$(LINKCC) $(PY_LDFLAGS) $(LINKFORSHARED) %s -o %s $(LDLAST)\n" %
28 outfp.write("\nclean:\n\t-rm -f *.o %s\n" % target)
Dfreeze.py446 with open(makefile, 'w') as outfp:
447 winmakemakefile.makemakefile(outfp,
455 with open(config_c_in) as infp, bkfile.open(config_c, 'w') as outfp:
456 makeconfig.makeconfig(infp, outfp, builtins)
474 with bkfile.open(makefile, 'w') as outfp:
475 makemakefile.makemakefile(outfp, somevars, files, base_target)
Dwinmakemakefile.py45 def makemakefile(outfp, vars, files, target): argument
48 sys.stdout = outfp
/third_party/python/Tools/scripts/
Deptags.py24 def treat_file(filename, outfp): argument
47 outfp.write('\f\n%s,%d\n' % (filename,size))
49 outfp.write(tag)
52 with open('TAGS', 'w') as outfp:
54 treat_file(filename, outfp)
/third_party/selinux/checkpolicy/
Dcheckmodule.c110 static int write_binary_policy(policydb_t * p, FILE *outfp) in write_binary_policy() argument
120 pf.fp = outfp; in write_binary_policy()
333 FILE *outfp = fopen(outfile, "w"); in main() local
335 if (!outfp) { in main()
341 if (write_binary_policy(&modpolicydb, outfp) != 0) { in main()
346 if (sepol_module_policydb_to_cil(outfp, &modpolicydb, 0) != 0) { in main()
352 if (fclose(outfp)) { in main()
Dcheckpolicy.c402 FILE *outfp = NULL; in main() local
657 outfp = stdout; in main()
660 outfp = fopen(outfile, "w"); in main()
661 if (!outfp) { in main()
673 pf.fp = outfp; in main()
684 ret = sepol_kernel_policydb_to_conf(outfp, policydbp); in main()
693 ret = sepol_kernel_policydb_to_cil(outfp, policydbp); in main()
695 ret = sepol_module_policydb_to_cil(outfp, policydbp, 1); in main()
703 if (outfp != stdout) { in main()
704 if(fclose(outfp)) { in main()
/third_party/python/Lib/test/
Dtest_quopri.py155 outfp = io.BytesIO()
156 quopri.encode(infp, outfp, quotetabs=False)
157 self.assertEqual(outfp.getvalue(), e)
163 outfp = io.BytesIO()
164 quopri.decode(infp, outfp)
165 self.assertEqual(outfp.getvalue(), p)
Dtest_base64.py65 outfp = BytesIO()
66 base64.encode(infp, outfp)
67 eq(outfp.getvalue(),
79 outfp = BytesIO()
80 base64.decode(infp, outfp)
81 self.assertEqual(outfp.getvalue(), b'www.python.org')
/third_party/python/Lib/
Dquopri.py111 outfp = BytesIO()
112 encode(infp, outfp, quotetabs, header)
113 return outfp.getvalue()
165 outfp = BytesIO()
166 decode(infp, outfp, header=header)
167 return outfp.getvalue()
/third_party/selinux/libsepol/fuzz/
Dbinpolicy-fuzzer.c8 static int write_binary_policy(policydb_t *p, FILE *outfp) in write_binary_policy() argument
14 pf.fp = outfp; in write_binary_policy()
/third_party/python/Doc/library/
Demail.generator.rst44 .. class:: BytesGenerator(outfp, mangle_from_=None, maxheaderlen=None, *, \
49 to the :meth:`write` method, to the :term:`file-like object` *outfp*.
50 *outfp* must support a ``write`` method that accepts binary data.
120 the exact same option settings, and *fp* as the new *outfp*.
126 handler, and pass it to the *write* method of the *outfp* passed to the
145 .. class:: Generator(outfp, mangle_from_=None, maxheaderlen=None, *, \
150 method, to the :term:`file-like object` *outfp*. *outfp* must support a
217 exact same options, and *fp* as the new *outfp*.
222 Write *s* to the *write* method of the *outfp* passed to the
241 .. class:: DecodedGenerator(outfp, mangle_from_=None, maxheaderlen=None, \
/third_party/python/Lib/email/
Dgenerator.py36 def __init__(self, outfp, mangle_from_=None, maxheaderlen=None, *, argument
63 self._fp = outfp
455 def __init__(self, outfp, mangle_from_=None, maxheaderlen=None, fmt=None, *, argument
478 Generator.__init__(self, outfp, mangle_from_, maxheaderlen,
/third_party/node/tools/icu/
Dshrink-icu-src.py42 def compress_data(infp, outfp): argument
44 with bz2.BZ2File(outfp, 'wb') as outf: