From bef1526d6175abf42de197c11e0022d301b70b76 Mon Sep 17 00:00:00 2001 From: marha Date: Wed, 29 Jul 2009 13:24:54 +0000 Subject: Installer now also install CRT --- xorg-server/installer/vcxsrv.nsi | 63 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) (limited to 'xorg-server/installer/vcxsrv.nsi') diff --git a/xorg-server/installer/vcxsrv.nsi b/xorg-server/installer/vcxsrv.nsi index e7ad98d81..66cd3db5b 100644 --- a/xorg-server/installer/vcxsrv.nsi +++ b/xorg-server/installer/vcxsrv.nsi @@ -36,6 +36,13 @@ Page instfiles UninstPage uninstConfirm UninstPage instfiles +SetPluginUnload alwaysoff +ShowInstDetails show +XPStyle on + +!define FUSION_REFCOUNT_UNINSTALL_SUBKEY_GUID {8cedc215-ac4b-488b-93c0-a50a49cb2fb8} + + ;-------------------------------- ; The stuff to install @@ -71,6 +78,41 @@ Section "VcXsrv (required)" WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\VcXsrv" "NoRepair" 1 WriteUninstaller "uninstall.exe" + InitPluginsDir + SetOutPath $PLUGINSDIR + File "C:\Windows\winsxs\x86_microsoft.vc90.crt_1fc8b3b9a1e18e3b_9.0.30729.1_none_e163563597edeada\msvcr90.dll" + File "C:\Windows\winsxs\x86_microsoft.vc90.crt_1fc8b3b9a1e18e3b_9.0.30729.1_none_e163563597edeada\msvcm90.dll" + File "C:\Windows\winsxs\x86_microsoft.vc90.crt_1fc8b3b9a1e18e3b_9.0.30729.1_none_e163563597edeada\msvcp90.dll" + File "C:\Windows\winsxs\manifests\x86_microsoft.vc90.crt_1fc8b3b9a1e18e3b_9.0.30729.1_none_e163563597edeada.cat" + File "C:\Windows\winsxs\manifests\x86_microsoft.vc90.crt_1fc8b3b9a1e18e3b_9.0.30729.1_none_e163563597edeada.manifest" + DetailPrint "Installing CRT assembly..." + System::Call "sxs::CreateAssemblyCache(*i .r0, i 0) i.r1" + StrCmp $1 0 0 fail + # Fill a FUSION_INSTALL_REFERENCE. + # fir.cbSize = sizeof(FUSION_INSTALL_REFERENCE) == 32 + # fir.dwFlags = 0 + # fir.guidScheme = FUSION_REFCOUNT_UNINSTALL_SUBKEY_GUID + # fir.szIdentifier = "nsissxs" + # fir.szNonCanonicalData = 0 + System::Call "*(i 32, i 0, i 2364391957, i 1217113163, i 178634899, i 3090139977, w 'nsissxs', w '') i.s" + Pop $2 + # IAssemblyCache::InstallAssembly(0, manifestPath, fir) + System::Call "$0->7(i 0, w '$PLUGINSDIR\x86_microsoft.vc90.crt_1fc8b3b9a1e18e3b_9.0.30729.1_none_e163563597edeada.manifest', i r2) i.r1" + System::Free $2 + StrCmp $1 0 0 fail2 + System::Call "$0->2()" + Goto end + +fail: + DetailPrint "CreateAssemblyCache failed." + DetailPrint $1 + Goto end + +fail2: + DetailPrint "InstallAssembly failed." + DetailPrint $1 + Goto end +end: SectionEnd ; Optional section (can be disabled by the user) @@ -127,4 +169,25 @@ Section "Uninstall" RMDir "$SMPROGRAMS\VcXsrv" RMDir "$INSTDIR" + DetailPrint "Removing CRT assembly..." + System::Call "sxs::CreateAssemblyCache(*i .r0, i 0) i.r1" + StrCmp $1 0 0 fail + System::Call "*(i 32, i 0, i 2364391957, i 1217113163, i 178634899, i 3090139977, w 'nsissxs', w '') i.s" + Pop $2 + System::Call "$0->3(i 0, w 'Microsoft.VC90.CRT,version=$\"9.0.21022.8$\",type=$\"win32$\",processorArchitecture=$\"x86$\",publicKeyToken=$\"1fc8b3b9a1e18e3b$\"', i r2, *i . r3) i.r1" + StrCmp $1 0 0 fail2 + DetailPrint "Disposition returned is $3" + System::Call "$0->2()" + Goto end + fail: + DetailPrint "CreateAssemblyCache failed." + DetailPrint $1 + Goto end + fail2: + DetailPrint "UninstallAssembly failed." + DetailPrint $1 + Goto end +end: + SectionEnd + -- cgit v1.2.3