fix(ci-installer): remove dynamic path defines for ISCC
Some checks failed
Desktop CI / tests (push) Successful in 12s
Desktop Release / release (push) Failing after 2m35s

- use static relative paths in .iss for source/output

- pass only version and /O override to ISCC

- add explicit source/script path diagnostics in build.py
This commit is contained in:
2026-02-15 22:42:39 +03:00
parent b1ed97a826
commit 02078282bc
2 changed files with 18 additions and 12 deletions

View File

@@ -200,18 +200,30 @@ def build_installer():
print("[ERROR] Install Inno Setup 6 or set ISCC_PATH environment variable.") print("[ERROR] Install Inno Setup 6 or set ISCC_PATH environment variable.")
sys.exit(1) sys.exit(1)
icon_abs_path = os.path.abspath(ICON_PATH) project_root = os.path.abspath(".")
source_dir = os.path.abspath(DIST_DIR)
output_dir = os.path.abspath("dist")
iss_path = os.path.abspath(INSTALLER_SCRIPT)
print(f"[INFO] ISCC source dir: {source_dir}")
print(f"[INFO] ISCC output dir: {output_dir}")
print(f"[INFO] ISCC script: {iss_path}")
if not os.path.exists(source_dir):
print(f"[ERROR] Source dir does not exist: {source_dir}")
sys.exit(1)
if not os.path.exists(iss_path):
print(f"[ERROR] Installer script does not exist: {iss_path}")
sys.exit(1)
command = [ command = [
iscc_path, iscc_path,
f"/DMyAppVersion={VERSION}", f"/DMyAppVersion={VERSION}",
f"/DMySourceDir={os.path.abspath(DIST_DIR)}", f"/O{output_dir}",
f"/DMyOutputDir={os.path.abspath('dist')}", iss_path,
os.path.abspath(INSTALLER_SCRIPT),
] ]
try: try:
completed = subprocess.run( completed = subprocess.run(
command, command,
capture_output=True, capture_output=True,
cwd=project_root,
check=False, check=False,
) )
stdout_text = _decode_process_output(completed.stdout) stdout_text = _decode_process_output(completed.stdout)

View File

@@ -2,12 +2,6 @@
#ifndef MyAppVersion #ifndef MyAppVersion
#define MyAppVersion "0.0.0" #define MyAppVersion "0.0.0"
#endif #endif
#ifndef MySourceDir
#define MySourceDir "..\\dist\\AnabasisManager"
#endif
#ifndef MyOutputDir
#define MyOutputDir "..\\dist"
#endif
[Setup] [Setup]
AppId={{6CD9D6F2-4B95-4E9C-A8D8-2A9C8F6AA741} AppId={{6CD9D6F2-4B95-4E9C-A8D8-2A9C8F6AA741}
@@ -18,7 +12,7 @@ DefaultDirName={localappdata}\Programs\Anabasis Manager
DefaultGroupName=Anabasis Manager DefaultGroupName=Anabasis Manager
DisableProgramGroupPage=yes DisableProgramGroupPage=yes
PrivilegesRequired=lowest PrivilegesRequired=lowest
OutputDir={#MyOutputDir} OutputDir=..\dist
OutputBaseFilename=AnabasisManager-setup-{#MyAppVersion} OutputBaseFilename=AnabasisManager-setup-{#MyAppVersion}
Compression=lzma2 Compression=lzma2
SolidCompression=yes SolidCompression=yes
@@ -34,7 +28,7 @@ Name: "english"; MessagesFile: "compiler:Default.isl"
Name: "desktopicon"; Description: "Create a desktop shortcut"; GroupDescription: "Additional tasks:" Name: "desktopicon"; Description: "Create a desktop shortcut"; GroupDescription: "Additional tasks:"
[Files] [Files]
Source: "{#MySourceDir}\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs Source: "..\dist\AnabasisManager\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs
[Icons] [Icons]
Name: "{group}\Anabasis Manager"; Filename: "{app}\AnabasisManager.exe" Name: "{group}\Anabasis Manager"; Filename: "{app}\AnabasisManager.exe"