V45.39: fix installer khong cai VC++ redist -> VST FX 0x7E tren may sach

Root cause: bridges (/MD) import MSVCP140.dll/VCRUNTIME140*.dll nhung installer
KHONG bao gio cai VC++ redist. hooks.nsh dinh nghia macro 'customInstall'
- ten Tauri v2 khong goi (template dung NSIS_HOOK_POSTINSTALL) -> macro chet,
vc_redist.x64.exe khong duoc nhung, khong chay. May phat trien chay duoc vi
co MSVC BuildTools (redist san); may user sach: bridge khong start duoc ->
moi VST/VST3 FX khong load (GUI khong mo), plugin /MD khac (iZotope core...)
bao 0x7E.

Fix:
- hooks.nsh: doi macro thanh NSIS_HOOK_POSTINSTALL; vc_redist dong goi nhu
  bundle resource ->  (File tuong doi trong macro resolve theo thu muc
  installer.nsi sinh ra, khong phai src-tauri -  cung vay).
  ExecWait /install /quiet /norestart; xoa file sau khi cai xong (rc 0/3010).
- tauri.conf.json: resources + vc_redist.x64.exe; nsis installMode perMachine
  (vc_redist can elevation; DAW scan Program Files plugin dirs).

Verified: 7z l installer -> vc_redist.x64.exe embedded; installer.nsi insert
NSIS_HOOK_POSTINSTALL; INSTALLMODE perMachine; makensis OK. NSIS +387MB.
MSI (WiX) van khong cai redist - can cai tay tren may dung MSI.
This commit is contained in:
2026-09-02 12:46:24 +07:00
parent 29b5f053a0
commit b153850d5c
2 changed files with 12 additions and 5 deletions
+8 -3
View File
@@ -1,7 +1,12 @@
; NSIS installer hooks — cai Microsoft Visual C++ Redistributable neu thieu
; (MSVCP140.dll missing). Dat vc_redist.x64.exe CANH tauri.conf.json
; (build_windows.ps1 tu tai ve neu chua co).
!macro customInstall
File "/oname=$PLUGINSDIR\vc_redist.x64.exe" "vc_redist.x64.exe"
ExecWait '"$PLUGINSDIR\vc_redist.x64.exe" /install /quiet /norestart'
!macro NSIS_HOOK_POSTINSTALL
; vc_redist.x64.exe dong goi nhu bundle resource -> $INSTDIR (khong dung File:
; path tuong doi trong macro resolve theo thu muc installer.nsi sinh ra).
ExecWait '"$INSTDIR\vc_redist.x64.exe" /install /quiet /norestart' $0
${If} $0 = 0
${OrIf} $0 = 3010
Delete "$INSTDIR\vc_redist.x64.exe"
${EndIf}
!macroend
+4 -2
View File
@@ -25,12 +25,14 @@
"resources": {
"resources/daw_engine": "daw_engine/",
"binaries/libfluidsynth-3.dll": "libfluidsynth-3.dll",
"binaries/jpeg62.dll": "jpeg62.dll"
"binaries/jpeg62.dll": "jpeg62.dll",
"vc_redist.x64.exe": "vc_redist.x64.exe"
},
"externalBin": ["binaries/daw_vst_bridge", "binaries/fx_vst_bridge", "binaries/plugin_host"],
"windows": {
"nsis": {
"installerHooks": "hooks.nsh"
"installerHooks": "hooks.nsh",
"installMode": "perMachine"
}
}
}