2021-01-18 13:04:53 -05:00
|
|
|
# Windows-only cx_freeze setup file
|
|
|
|
from cx_Freeze import setup, Executable
|
|
|
|
import sys
|
|
|
|
import os
|
|
|
|
import shutil
|
|
|
|
|
2021-03-24 12:27:09 -04:00
|
|
|
from version import _pcVersion
|
|
|
|
|
2021-01-18 13:04:53 -05:00
|
|
|
if sys.platform == "win32":
|
|
|
|
base = "Win32GUI"
|
|
|
|
|
|
|
|
build_exe_options = {
|
|
|
|
"includes": ["requests","urllib"],
|
|
|
|
'excludes': ['collections.sys',
|
|
|
|
'collections._sre',
|
|
|
|
'collections._json',
|
|
|
|
'collections._locale',
|
|
|
|
'collections._struct',
|
|
|
|
'collections.array',
|
2021-02-23 10:27:29 -05:00
|
|
|
'collections._weakref'],
|
2021-01-18 13:04:53 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
setup(
|
2021-03-24 12:27:09 -04:00
|
|
|
name = "Pesterchum",
|
|
|
|
version = str(_pcVersion),
|
|
|
|
description = "Pesterchum Alt. 2.0 :)",
|
2021-01-18 13:04:53 -05:00
|
|
|
options = {"build_exe": build_exe_options},
|
|
|
|
executables = [Executable("pesterchum.py",
|
|
|
|
base=base,
|
|
|
|
icon="pesterchum.ico",
|
|
|
|
),
|
|
|
|
Executable("pesterchum_debug.py",
|
|
|
|
base=base,
|
|
|
|
icon="pesterchum.ico",
|
|
|
|
)])
|
|
|
|
|
2021-03-24 12:27:09 -04:00
|
|
|
#if sys.platform == "win32":
|
|
|
|
# os.rename("build/exe.win32-2.7", "build/pesterchum")
|
2021-01-18 13:04:53 -05:00
|
|
|
|
|
|
|
shutil.copytree("themes", "build/pesterchum/themes")
|
|
|
|
shutil.copytree("smilies", "build/pesterchum/smilies")
|
|
|
|
shutil.copytree("quirks", "build/pesterchum/quirks")
|
2021-03-24 12:27:09 -04:00
|
|
|
#shutil.copy("pesterchum.nsi", "build/pesterchum/")
|
|
|
|
#shutil.copy("pesterchum-update.nsi", "build/pesterchum/")
|
|
|
|
#os.mkdir("build/pesterchum/profiles")
|
|
|
|
#os.mkdir("build/pesterchum/logs")
|
2021-01-18 13:04:53 -05:00
|
|
|
|
|
|
|
#Readme & txt
|
2021-03-24 12:27:09 -04:00
|
|
|
#shutil.copy("README.md", "build/pesterchum/")
|
|
|
|
#shutil.copy("README-pesterchum.mkdn", "build/pesterchum/")
|
|
|
|
#shutil.copy("README-karxi.mkdn", "build/pesterchum/")
|
|
|
|
#shutil.copy("themes.txt", "build/pesterchum/")
|