GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — plot_PDOS/PDOS-Viewer.spec at main · moyulyy/plot_PDOS Expand file tree/ Copy pathPDOS-Viewer.specMore file actions 89 lines (78 loc) · 2.24 KB / Copy pathPDOS-Viewer.specFile metadata and controls89 lines (78 loc) · 2.24 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 # -*- mode: python ; coding: utf-8 -*- """PyInstaller 打包配置 —— PDOS · 结构分析工作台(Windows 便携版) 构建: pyinstaller --noconfirm --clean PDOS-Viewer.spec 产物: dist/PDOS-Viewer/PDOS-Viewer.exe ← 双击即可运行 dist/PDOS-Viewer/_internal/ ← 运行时依赖(QtWebEngine / Qt / matplotlib) 打包后程序的目录约定(见 pdos_viewer.py 顶部 APP_DIR / RES_DIR): APP_DIR = exe 所在目录 —— 数据文件夹、导出文件、运行期生成的 _viewer.html RES_DIR = sys._MEIPASS —— 打包进来的只读资源(assets/、3dmol/) """ from pathlib import Path ROOT = Path(SPECPATH) # 只读资源:程序图标 + 3Dmol.js(运行期需要写 _viewer.html,会复制到 exe 同级 3dmol/) datas = [ (str(ROOT / "assets" / "app.ico"), "assets"), (str(ROOT / "3dmol" / "3Dmol-min.js"), "3dmol"), ] hiddenimports = [ # QtWebEngine 相关(动态导入,显式声明更稳) "PySide6.QtWebEngineWidgets", "PySide6.QtWebEngineCore", "PySide6.QtWebChannel", "PySide6.QtPrintSupport", # matplotlib 的 Qt 后端 "matplotlib.backends.backend_qtagg", "matplotlib.backends.backend_agg", # Excel 导出 "openpyxl", "openpyxl.styles", "openpyxl.utils", "et_xmlfile", ] a = Analysis( [str(ROOT / "pdos_viewer.py")], pathex=[str(ROOT)], binaries=[], datas=datas, hiddenimports=hiddenimports, hookspath=[], hooksconfig={}, runtime_hooks=[], excludes=[ "tkinter", "PyQt5", "PyQt6", "PySide2", "IPython", "jupyter", "notebook", "pytest", ], noarchive=False, optimize=0, ) pyz = PYZ(a.pure) exe = EXE( pyz, a.scripts, [], exclude_binaries=True, name="PDOS-Viewer", debug=False, bootloader_ignore_signals=False, strip=False, upx=False, console=False, # 无控制台窗口(GUI 程序) disable_windowed_traceback=False, argv_emulation=False, target_arch=None, codesign_identity=None, entitlements_file=None, icon=str(ROOT / "assets" / "app.ico"), ) coll = COLLECT( exe, a.binaries, a.datas, strip=False, upx=False, upx_exclude=[], name="PDOS-Viewer", ) |
| You are visitor 01402792 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |