mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-01 09:23:03 -04:00
deploy-ng: Ensure sys.frozen is defined in frozen applications
This commit is contained in:
parent
8c5c2c3c7d
commit
dd9a7f31ec
@ -74,6 +74,8 @@ PACKAGE_DATA_DIRS = {
|
||||
SITE_PY2 = u"""
|
||||
import sys
|
||||
|
||||
sys.frozen = True
|
||||
|
||||
# Override __import__ to set __file__ for frozen modules.
|
||||
prev_import = __import__
|
||||
def __import__(*args, **kwargs):
|
||||
@ -110,6 +112,8 @@ SITE_PY3 = u"""
|
||||
import sys
|
||||
from _frozen_importlib import _imp, FrozenImporter
|
||||
|
||||
sys.frozen = True
|
||||
|
||||
if sys.platform == 'win32':
|
||||
# Make sure the preferred encoding is something we actually support.
|
||||
import _bootlocale
|
||||
|
Loading…
x
Reference in New Issue
Block a user