22 lines
2.5 KiB
Markdown
22 lines
2.5 KiB
Markdown
# Windows self-extracting release
|
|
|
|
Build the complete application with `Build-DxPartReplace.ps1` first. The spec now fails if the installed DSH package, reporter configuration or Node executable is missing. Keep the entire installed `integration/dsh/node_modules` tree, including lazy runtime dependencies.
|
|
|
|
Use the official **7-Zip 26.05 x64** tools from:
|
|
|
|
- Binary: https://github.com/ip7z/7zip/releases/download/26.05/7z2605-x64.exe
|
|
- SHA256: `fd99e86f57d8f429ef5ed045bf98315af962e2309b0f1ba87a147a44c71647d0`
|
|
- Source and license: https://github.com/ip7z/7zip/releases/tag/26.05 and https://www.7-zip.org/license.txt
|
|
|
|
Extract the installer with an existing 7-Zip tool into a build-only directory. No machine-wide installation is needed. Use that directory's `7z.exe`, `7z.dll`, `7z.sfx` and `License.txt`. The standard `7z.sfx` opens a destination selector and extracts to a persistent directory. It is not the install-to-temp SFX module; it takes no installer configuration and does not auto-launch or delete the extracted application.
|
|
|
|
```powershell
|
|
python tools/build_self_extracting_release.py --source-dir dist/DxPartReplace --output-dir G:/dx-release-1.2.2 --version 1.2.2 --seven-zip build/7zip-2605/full/7z.exe --sfx-stub build/7zip-2605/full/7z.sfx --license build/7zip-2605/full/License.txt
|
|
```
|
|
|
|
Use a fresh output directory and keep the completed build input unchanged during packaging. The tool rejects an existing directory, overlapping input/output paths and an application input containing `data`. It stages the complete input using same-volume hardlinks (copying when links are unavailable), includes the 7-Zip license, produces independent EXE + ZIP archives, and writes artifact and per-file SHA256 hashes. LZMA2 level 3 and bounded solid blocks keep decoding memory modest; tiny files still incur filesystem costs, so do not promise a fixed speedup across machines.
|
|
|
|
Before publishing, run the self-extracting EXE itself with `-y -o<fresh directory>`, compare every resulting file and every ZIP member against the manifest, and run `tools/verify_packaged_runtime.py` and Qt/DSH UI acceptance on that extracted EXE. Neither merely listing the archive nor the source UI tests replaces this check.
|
|
|
|
The optional Windows integration test exercises the real SFX with Chinese/spaced paths and empty/binary files. Set `DX_SFX_TEST_TOOLS` to the official tools directory and run `python -m pytest tests/packaging/test_self_extracting_release.py`. Linux CI runs the portable output-protection checks and explicitly skips the Windows integration.
|