mirror of
				https://github.com/kovidgoyal/calibre.git
				synced 2025-11-04 03:27:00 -05:00 
			
		
		
		
	
		
			
				
	
	
		
			20 lines
		
	
	
		
			604 B
		
	
	
	
		
			Python
		
	
	
		
			Executable File
		
	
	
	
	
			
		
		
	
	
			20 lines
		
	
	
		
			604 B
		
	
	
	
		
			Python
		
	
	
		
			Executable File
		
	
	
	
	
#------------------------------------------------------------------------------
 | 
						|
# ConsoleKeepPath.py
 | 
						|
#   Initialization script for cx_Freeze which leaves the path alone and does
 | 
						|
# not set the sys.frozen attribute.
 | 
						|
#------------------------------------------------------------------------------
 | 
						|
 | 
						|
import sys
 | 
						|
import zipimport
 | 
						|
 | 
						|
m = __import__("__main__")
 | 
						|
importer = zipimport.zipimporter(INITSCRIPT_ZIP_FILE_NAME)
 | 
						|
code = importer.get_code(m.__name__)
 | 
						|
exec code in m.__dict__
 | 
						|
 | 
						|
if sys.version_info[:2] >= (2, 5):
 | 
						|
    module = sys.modules.get("threading")
 | 
						|
    if module is not None:
 | 
						|
        module._shutdown()
 | 
						|
 |