-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsetup.py
More file actions
56 lines (48 loc) · 1.4 KB
/
setup.py
File metadata and controls
56 lines (48 loc) · 1.4 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
import sys
from cx_Freeze import Executable, setup
from pathlib import Path, PosixPath
try:
from cx_Freeze.hooks import get_qt_plugins_paths
except ImportError:
include_files = []
else:
# Inclusion of extra plugins (new in cx_Freeze 6.8b2)
# cx_Freeze imports automatically the following plugins depending of the
# use of some modules:
# imageformats - QtGui
# platforms - QtGui
# mediaservice - QtMultimedia
# printsupport - QtPrintSupport
#
# So, "platforms" is used here for demonstration purposes.
include_files = get_qt_plugins_paths("PyQt5", "platforms")
include_files.append(Path("config.ini"))
include_files.append([Path("ui/icons/"), 'ui/icons/'])
# base="Win32GUI" should be used only for Windows GUI app
base = None
if sys.platform == "win32":
base = "Win32GUI"
build_exe_options = {
"excludes": ["tkinter"],
"include_files": include_files,
"path": sys.path
}
# bdist_mac_options = {
# "bundle_name": "Test",
# }
#
# bdist_dmg_options = {
# "volume_label": "TEST",
# }
executables = [Executable("client.py", base=base, target_name="client"),
Executable("server.py", base=base, target_name="server")]
setup(
name="The Unitum",
version="0.0.1",
options={
"build_exe": build_exe_options,
# "bdist_mac": bdist_mac_options,
# "bdist_dmg": bdist_dmg_options,
},
executables=executables,
)