Commit 2f378772 authored by Guido van Rossum's avatar Guido van Rossum

If freezing with the -O option, the optimized bytecode files are

used.  It is useful to implicitly set the -O flag in the frozen
application.
(Sjoerd Mullender)
parent 3fde5371
......@@ -14,12 +14,16 @@ trailer = """\
};
"""
# if __debug__ == 0 (i.e. -O option given), set Py_OptimizeFlag in frozen app.
default_entry_point = """
int
main(argc, argv)
int argc;
char **argv;
{
""" + ((not __debug__ and """
Py_OptimizeFlag++;
""") or "") + """
PyImport_FrozenModules = _PyImport_FrozenModules;
return Py_FrozenMain(argc, argv);
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment