Difference between revisions of "Virtual PC"

From WPKG | Open Source Software Deployment and Distribution
Jump to: navigation, search
(added info on Windows Virtual PC, for Windows 7)
(Fixed situation where WPKG would think the install had failed)
Line 15: Line 15:
  
 
Windows Virtual PC is a free add-on to Windows 7. See [http://support.microsoft.com/kb/958559 KB958559] for information and a download link. For Windows 8, it's been replaced with Hyper-V.
 
Windows Virtual PC is a free add-on to Windows 7. See [http://support.microsoft.com/kb/958559 KB958559] for information and a download link. For Windows 8, it's been replaced with Hyper-V.
 
While I tested the individual commands, this silent installer has not yet been fully tested because I decided on a solution that did not require Virtual PC. I'm posting it to the wiki in case it will be of use to others. If you verify that it works, please remove this note.
 
  
 
<source lang="xml">
 
<source lang="xml">
Line 38: Line 36:
 
     <check type="uninstall" condition="exists" path="" />
 
     <check type="uninstall" condition="exists" path="" />
  
     <install cmd="wusa &quot;%PKG_SOURCE%&quot; /quiet /norestart" />
+
     <install cmd="wusa &quot;%PKG_SOURCE%&quot; /quiet /norestart" >
 +
      <exit code="0" />
 +
      <exit code="3010" /> <!-- add reboot="postponed" to force a reboot; otherwise, Windows will ask the user -->
 +
      <exit code="-2145124329" /> <!-- already installed -->
 +
    </install>
  
 
     <upgrade include="install" />
 
     <upgrade include="install" />
  
     <remove cmd="wusa /uninstall /kb:958559 /quiet /norestart" />
+
     <remove cmd="wusa /uninstall /kb:958559 /quiet /norestart" >
 +
      <exit code="any" />
 +
    </remove>
 +
 
  
 
</package>
 
</package>

Revision as of 22:38, 16 January 2014

VirtualPC 2007

This is a silent installer for Virtual PC 2007. Follow the instructions first. For more infos see here.

<package id="vpc2007" name="virtual pc 2007" revision="1" reboot="false" priority="10">
        <check type="uninstall" condition="exists" path="Microsoft Virtual PC 2007" />
        <install cmd='"%SOFTWARE%\vpc2007\msxml6-KB927977-enu-x86.exe" /quiet'/>
        <install cmd='msiexec /q /i "%SOFTWARE%\vpc2007\Virtual_PC_2007_Install.msi" allusers=2'/>
        <upgrade cmd='msiexec /q /i "%SOFTWARE%\vpc2007\Virtual_PC_2007_Install.msi" allusers=2'/>
        <remove cmd='MsiExec.exe /q /x{8A7CAA24-7B23-410B-A7C3-F994B0944160}' />
</package>

Windows Virtual PC

Windows Virtual PC is a free add-on to Windows 7. See KB958559 for information and a download link. For Windows 8, it's been replaced with Hyper-V.

<package
   id="virtualpc"
   name="Microsoft Virtual PC"
   revision="2-%VPC_VERSION"
   reboot="false"
   priority="0">

    <variable name="VPC_VERSION"    value="6.1.7601.17514" />
    <variable name="PKG_SOURCE"         value="%SOFTWARE%\virtualpc\Windows6.1-KB958559-x86-RefreshPkg.msu" architecture="x86"/>
    <variable name="PKG_SOURCE"         value="%SOFTWARE%\virtualpc\Windows6.1-KB958559-x64-RefreshPkg.msu" architecture="x64"/>

    <check type="file" condition="versiongreaterorequal" path="%WINDIR%\system32\vpc.exe" value="%VPC_VERSION%" />

    <!-- Warning: the KB977632 hotfix is needed if for some reason you're
         installing this on Windows 7 without SP1. You probably shouldn't be
         running non-SP1 Windows 7 anyway. -->

    <check type="uninstall" condition="exists" path="" />

    <install cmd="wusa &quot;%PKG_SOURCE%&quot; /quiet /norestart" >
      <exit code="0" />
      <exit code="3010" /> <!-- add reboot="postponed" to force a reboot; otherwise, Windows will ask the user -->
      <exit code="-2145124329" /> <!-- already installed -->
    </install>

    <upgrade include="install" />

    <remove cmd="wusa /uninstall /kb:958559 /quiet /norestart" >
      <exit code="any" />
    </remove>


</package>