-
Notifications
You must be signed in to change notification settings - Fork 29
Expand file tree
/
Copy pathbuild-macos.spec
More file actions
149 lines (142 loc) · 3.5 KB
/
Copy pathbuild-macos.spec
File metadata and controls
149 lines (142 loc) · 3.5 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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
# -*- mode: python ; coding: utf-8 -*-
"""
PyInstaller spec for the macOS webot app.
Build: .venv/bin/pyinstaller build-macos.spec
Output: dist/webot.app
"""
import os
from pathlib import Path
MACOS_CODESIGN_IDENTITY = os.getenv("MACOS_CODESIGN_IDENTITY") or None
MACOS_ENTITLEMENTS_FILE = "macos-entitlements.plist"
PROJECT_ROOT = Path(SPECPATH)
WEFLOW_WCDB_DIR = PROJECT_ROOT / "native" / "macos"
WEFLOW_WCDB_BINARIES = [
(str(path), "native/macos")
for path in (WEFLOW_WCDB_DIR / "libWCDB.dylib",)
if path.exists()
]
a = Analysis(
["desktop_mac.py"],
pathex=[],
binaries=WEFLOW_WCDB_BINARIES,
datas=[
("ui/dist", "ui/dist"),
(".env.example", "."),
],
hiddenimports=[
"src",
"src.admin",
"src.bot",
"src.config",
"src.db",
"src.db.schema",
"src.db.store",
"src.fun",
"src.integrations",
"src.integrations.feishu",
"src.integrations.feishu.client",
"src.integrations.feishu.exporter",
"src.integrations.feishu.knowledge",
"src.memory",
"src.memory.consolidator",
"src.nickname",
"src.proactive",
"src.proactive.gate",
"src.proactive.modes",
"src.proactive.rate_tracker",
"src.proactive.sticky",
"src.router",
"src.summarize",
"src.summarize.base",
"src.summarize.claude_backend",
"src.summarize.deepseek_backend",
"src.summarize.models",
"src.summarize.prompts",
"src.trigger",
"src.trigger.detector",
"src.utils",
"src.utils.logging_config",
"src.web",
"src.web.server",
"src.wechat",
"src.wechat.base",
"src.wechat.mac_hybrid_backend",
"src.wechat.mac_ui_backend",
"src.wechat.mac_weflow_client",
"anthropic",
"openai",
"pydantic",
"dotenv",
"ddgs",
"PIL",
"PIL.Image",
"PIL.ImageDraw",
"pyperclip",
"psutil",
"AppKit",
"Quartz",
"objc",
"webview",
"webview.platforms",
"webview.platforms.cocoa",
],
hookspath=[],
hooksconfig={},
runtime_hooks=[],
excludes=[
"tkinter",
"matplotlib",
"numpy",
"scipy",
"jedi",
"IPython",
"uiautomation",
"win32api",
"win32con",
"win32gui",
"win32clipboard",
"win32process",
"comtypes",
],
noarchive=False,
optimize=0,
)
pyz = PYZ(a.pure)
exe = EXE(
pyz,
a.scripts,
[],
exclude_binaries=True,
name="webot",
debug=False,
bootloader_ignore_signals=False,
strip=False,
upx=True,
console=False,
disable_windowed_traceback=False,
argv_emulation=False,
target_arch=None,
codesign_identity=MACOS_CODESIGN_IDENTITY,
entitlements_file=MACOS_ENTITLEMENTS_FILE,
)
coll = COLLECT(
exe,
a.binaries,
a.datas,
strip=False,
upx=True,
upx_exclude=[],
name="webot",
)
app = BUNDLE(
coll,
name="webot.app",
icon=None,
bundle_identifier="com.webot.desktop",
codesign_identity=MACOS_CODESIGN_IDENTITY,
entitlements_file=MACOS_ENTITLEMENTS_FILE,
info_plist={
"NSAppleEventsUsageDescription": "webot needs to control WeChat and System Events to switch chats and send replies.",
"NSScreenCaptureUsageDescription": "webot needs to read the visible WeChat chat title and search results on macOS.",
},
)