mirror of
https://github.com/panda3d/panda3d.git
synced 2025-09-27 07:03:36 -04:00
deploy-stub: Set Py_OptimizeFlag
to 2 for Python 3.2+
This fixes the value of `sys.flags.optimize`, as we always build Python code with `optimize=2` in Python 3.2 and above In the long run we need a better solution, see #1363 Closes #1359 Fixes #1343
This commit is contained in:
parent
8617eb917c
commit
3e220e4fb4
@ -441,6 +441,10 @@ int Py_FrozenMain(int argc, char **argv)
|
||||
Py_NoSiteFlag = 0;
|
||||
Py_NoUserSiteDirectory = 1;
|
||||
|
||||
#if PY_VERSION_HEX >= 0x03020000
|
||||
Py_OptimizeFlag = 2;
|
||||
#endif
|
||||
|
||||
#ifndef NDEBUG
|
||||
if ((p = Py_GETENV("PYTHONINSPECT")) && *p != '\0')
|
||||
inspect = 1;
|
||||
|
Loading…
x
Reference in New Issue
Block a user