Advertisement
Guest User

Untitled

a guest
Mar 26th, 2019
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.88 KB | None | 0 0
  1. from cx_Freeze import setup, Executable
  2. import sys
  3. import os.path
  4. PYTHON_INSTALL_DIR = os.path.dirname(os.path.dirname(os.__file__))
  5. os.environ['TCL_LIBRARY'] = os.path.join(PYTHON_INSTALL_DIR, 'tcl', 'tcl8.6')
  6. os.environ['TK_LIBRARY'] = os.path.join(PYTHON_INSTALL_DIR, 'tcl', 'tk8.6')
  7. base = None
  8. if sys.platform == 'win32':
  9.     base = None
  10.  
  11. executables = [Executable("main.py", base=base)]
  12.  
  13. include_files = [(os.path.join(PYTHON_INSTALL_DIR, 'DLLs', 'tk86t.dll'), os.path.join('lib', 'tk86t.dll')),
  14.                  (os.path.join(PYTHON_INSTALL_DIR, 'DLLs', 'tcl86t.dll'), os.path.join('lib', 'tcl86t.dll'))]
  15.  
  16. packages = []
  17. options = {
  18.     'build_exe': {
  19.  
  20.         'packages':packages,
  21.         'include_files': include_files
  22.     }
  23. }
  24.  
  25. setup(
  26.     name = "",
  27.     options = options,
  28.     version = "0.1",
  29.     description = '<any description>',
  30.     executables = executables
  31. )
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement