﻿<?xml version="1.0" encoding="UTF-8"?>

<!--

Copyright (C) 2006 Open Plan IT
Licence: GNU General Public License version 2
Version: 0.5

See http://thegoldenear.org/

-->

<packages>

	<package
		id="7-zip"
		name="7-Zip"
		revision="1"
		reboot="false"
		priority="1">

		<check
			type="registry"
			condition="exists"
			path="HKLM\Software\7-Zip\Path" />

		<install cmd="%PACKAGES%\7-zip\7z442.exe /S" />

		<upgrade cmd="%PACKAGES%\7-zip\7z442.exe /S" />

		<remove
			cmd="%PROGRAMFILES%\7-Zip\Uninstall.exe /S" />
		<!-- 7-Zip uninstaller wants to reboot -->
	</package>


	<package
		id="afpl-ghostscript"
		name="AFPL Ghostscript"
		revision="1"
		reboot="false"
		priority="2" >

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\gs\gs8.54\bin\gswin32.exe" />

		<install
			cmd="%PACKAGES%\afpl-ghostscript\gs854w32.exe /verysilent /suppressmsgboxes" />
<!-- %PACKAGES%\afpl-ghostscript\setupgs.exe -title "AFPL Ghostscript #.##" -dir "gs#.##" -list "filelist.txt" spec1 spec2 specn -->

		<upgrade
			cmd="%PACKAGES%\afpl-ghostscript\gs854w32.exe /verysilent /suppressmsgboxes" />

			<remove
			cmd='%PROGRAMFILES%\gs\uninstgs.exe %PROGRAMFILES%\gs\gs8.54\uninstal.txt '/>

		<remove
			cmd='%PROGRAMFILES%\gs\uninstgs.exe %PROGRAMFILES%\gs\fonts\uninstal.txt' />

		<upgrade
			cmd="" />
	</package>

	
	
	<package
		id="audacity"
		name="Audacity"
		revision="1"
		reboot="false"
		priority="1">

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\Audacity\audacity.exe" />
		<!-- Audacity doesn't use the registry's HKLM  -->

		<install
			cmd="%PACKAGES%\audacity\audacity-win-1.2.5.exe /sp- /silent /nocancel /norestart /log" />

		<upgrade
			cmd="%PACKAGES%\audacity\audacity-win-1.2.5.exe /sp- /silent /nocancel /norestart /log" />

		<remove
			cmd="%PROGRAMFILES%\Audacity\unins000.exe /silent /log /norestart" />
	</package>


	<package
		id="adobe-reader"
		name="Adobe Reader"
		revision="1"
		reboot="false"
		priority="1">

		<check
			type="registry"
			condition="exists"
			path="HKLM\SOFTWARE\Adobe\Acrobat Reader\7.0\Installer\Path" />

		<install
			cmd='msiexec /qb /package "%PACKAGES%\adobe-reader\Adobe Reader 7.0.8.msi"' />

		<upgrade
			cmd='msiexec /qb /package "%PACKAGES%\adobe-reader\Adobe Reader 7.0.8.msi"' />

			<remove
			cmd="MsiExec.exe /qb /uninstall {AC76BA86-7AD7-1033-7B44-A70800000002}" >
			<exit
				code="3010" /></remove>
		<!-- the '1033' locale ID in the above alphanumeric string relates to English (US); if you use a different loacle you'll have to change this respectively -->
		<!-- Adobe Reader wants a restart after removing -->
		<!-- Adobe Reader can give the exit code 1605 'this action is only valid for products that are currently installed',
		presumably when it tries to uninstall it when its already uninstalled, or was it because I had A705 rather than A708? -->
		<!-- the A708 in the alphanumeric string relates to the Adobe Reader version number -->

		<upgrade
			cmd='msiexec /qb /package "%PACKAGES%\adobe-reader\Adobe Reader 7.0.8.msi"'>
			<exit
				code="3010" /></upgrade>
				<!-- 3010 means it needs a reboot -->
	</package>

	
	<package
		id="ad-aware-se-personal"
		name="Ad-Aware"
		revision="1"
		priority="1"
		reboot="false">

		<check
			type="uninstall"
			condition="exists"
			path="Ad-Aware SE Personal" />
			<!-- Ad-Aware doesn't appear to use HKLM -->

		<install
			cmd="%PACKAGES%\ad-aware-se-personal\aawsepersonal.exe /s" />

		<upgrade
			cmd="%PACKAGES%\ad-aware-se-personal\aawsepersonal.exe /s" />

			<remove
			cmd='%PROGRAMFILES%\Lavasoft\Ad-Aware SE Personal\UNWISE.EXE /S /Z "%PROGRAMFILES%\Lavasoft\Ad-Aware SE Personal\INSTALL.LOG"' />
			<!-- Needs to be pointed to its install.log; needs to be quoted -->
	</package>


	<package
		id="aspell"
		name="Aspell"
		revision="1"
		reboot="false"
		priority="1">

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\Aspell\bin\aspell.exe" />

		<install
			cmd="%PACKAGES%\aspell\Aspell-0-50-3-3-Setup.exe /sp- /silent /nocancel /norestart /log" />

		<upgrade
			cmd="%PACKAGES%\aspell\Aspell-0-50-3-3-Setup.exe /sp- /silent /nocancel /norestart /log" />

		<remove
			cmd="%PROGRAMFILES%\Aspell\unins000.exe /silent /log /norestart" />

	</package>


	<package
		id="aspell-dictionary-english"
		name="Aspell dictionary (English)"
		revision="1"
		reboot="false"
		priority="1">

		<depends
			package-id="aspell" />

			<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\Aspell\data\en.dat" />

		<install
			cmd="%PACKAGES%\aspell-dictionaries\english\setup-Aspell-en-0.50-2.exe /sp- /silent /nocancel /norestart /log" />

		<upgrade
			cmd="%PACKAGES%\aspell-dictionaries\Aspell-0-50-3-3-Setup.exe /sp- /silent /nocancel /norestart /log" />

		<remove
			cmd="%PROGRAMFILES%\Aspell\unins001.exe /silent /log /norestart" />

	</package>


	<package
		id="dia"
		name="Dia"
		revision="1"
		reboot="false"
		priority="1">

		<depends
			package-id="gtk" />

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\Dia\bin\dia.exe" />

		<install
			cmd='%PACKAGES%\dia\dia-setup-0.95-1.exe /S'/>

		<upgrade
			cmd='%PACKAGES%\dia\dia-setup-0.95-1.exe /S'/>

		<remove
			cmd="%PROGRAMFILES%\Dia\dia-0.95-1-uninstall.exe /S" />
	</package>

	
	<package
		id="enigmail"
		name="Enigmail"
		revision="1"
		reboot="false"
		priority="1">

		<depends
			package-id="thunderbird" />

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\Mozilla Thunderbird\extensions\{847b3a00-7ab1-11d4-8f02-006008948af5}\components\enigmail.js" />

		<install
			cmd='cmd /c "IF NOT EXIST "%PROGRAMFILES%\Mozilla Thunderbird\extensions\{847b3a00-7ab1-11d4-8f02-006008948af5}" mkdir "%PROGRAMFILES%\Mozilla Thunderbird\extensions\{847b3a00-7ab1-11d4-8f02-006008948af5}""' />

		<install
			cmd='cmd /c ""%WPKGROOT%\tools\unzip" -o "%PACKAGES%\enigmail\enigmail-0.94.1-tb15-win32.xpi" -d "%PROGRAMFILES%\Mozilla Thunderbird\extensions\{847b3a00-7ab1-11d4-8f02-006008948af5}""' />

		<upgrade
			cmd='cmd /c "IF NOT EXIST "%PROGRAMFILES%\Mozilla Thunderbird\extensions\{847b3a00-7ab1-11d4-8f02-006008948af5}" mkdir "%PROGRAMFILES%\Mozilla Thunderbird\extensions\{847b3a00-7ab1-11d4-8f02-006008948af5}""' />

		<upgrade
			cmd='cmd /c ""%WPKGROOT%\tools\unzip" -o "%PACKAGES%\enigmail\enigmail-0.94.1-tb15-win32.xpi" -d "%PROGRAMFILES%\Mozilla Thunderbird\extensions\{847b3a00-7ab1-11d4-8f02-006008948af5}""' />
	</package>


	<package
		id="eraser"
		name="Eraser"
		revision="1"
		reboot="false"
		priority="1">

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\Eraser\eraser.exe" />

		<install
			cmd="%PACKAGES%\eraser\eraser58setup.exe /sp- /silent /nocancel /norestart /log" />

		<upgrade
			cmd="%PACKAGES%\eraser\eraser58setup.exe /sp- /silent /nocancel /norestart /log" />

		<remove
			cmd="%PROGRAMFILES%\Eraser\unins000.exe /silent /log /norestart" />
	</package>

	
	<package
		id="evolution"
		name="Evolution"
		revision="1"
		reboot="false"
		priority="1">

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\evolution\bin\evolution-2.6.exe" />

		<install
			cmd='msiexec /qb /package "%PACKAGES%\evolution\Evolution-2.6.2-5.msi"' />

		<upgrade
			cmd='msiexec /qb /package "%PACKAGES%\evolution\Evolution-2.6.2-5.msi"' />

			<remove
			cmd="MsiExec.exe /qb /uninstall {CD1286C6-4305-47BD-A0C0-B41716D70307}" />
	</package>


			
				

<package
		id="f-prot"
		name="F-Prot"
		revision="1"
		reboot="false"
		priority="1">
		<!-- F-Prot wants to reboot -->
 
		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\FRISK Software\F-PROT Antivirus for Windows\FPWin.exe" />

		<install
			cmd='msiexec /qb /package "%PACKAGES%\f-prot\fpav-windows-x86-hc-en.msi"' />
		<!-- F-Prot wants to reboot and issues a message asking the user to accept or decline (could be fixed with /qb?) -->

		<!-- install and uninstall now work, but product is not activated due to lack of subscription key, could we place our key in a text file and point the installer to it
		using [PKFILE=filename] as used by various ms programs? (example subscription key from FRISK AHL9AC-CDT74U-45GDFZ-DAG5LR-TWVEBB-2BN2)

		Also worth noting - although current 3.xx key won't work with beta, we can apply for a new key using an old one and all product subscriptions will be 
		transfered on final release. I have emailed FRISK to ask about silent installer options, why the options are so MS specific and if this is actually true or if
		the "protection" applies more generically to mail clients and browsers and also if the options which are no longer present in the UI have merely been replaced
		be default options or if they have been migrated to a config file somewhere (I was not able to find one, could it be that other setting may be possible at a 
		registry level?.-->

<!--  potential worthwhile f-prot settings:
- unwanted programs...

issues:
system status doesn't say what version of program is running, or at least say we have the latest
"Backed up files are keep in your computer within 30 days"
patchy remembering of settings for play sound and check for unwanted programs -->


		<upgrade
			cmd='msiexec /qb /package "%PACKAGES%\f-prot\fpav-windows-x86-hc-en.msi"' />

		<remove
				cmd="msiexec /qb /uninstall {0BBD978D-EF4A-469A-8861-A1884B22E322}" />
	</package>

	
	<package
		id="filezilla"
		name="FileZilla"
		revision="1"
		reboot="false"
		priority="1">

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\Filezilla\FileZilla.exe" />

		<install
			cmd="%PACKAGES%\filezilla\FileZilla_2_2_29_setup.exe /S" />

		<upgrade
			cmd="%PACKAGES%\filezilla\FileZilla_2_2_29_setup.exe /S" />

		<remove
			cmd="%PROGRAMFILES%\FileZilla\Uninstall.exe /S" />
	</package>


	
	
	<package 
		id="firefox" 
		name="Mozilla Firefox" 
		revision="1"
		reboot="false" 
		priority="1">

		<check
			type="uninstall"
			condition="exists"
			path="Mozilla Firefox (2.0)" />

		<install
			cmd="%PACKAGES%\firefox\Firefox Setup 2.0 RC 3.exe /S" />

		<upgrade
			cmd="%PACKAGES%\firefox\Firefox Setup 2.0 RC 3.exe /S" />

		<remove
			cmd="%PROGRAMFILES%\Mozilla Firefox\uninstall\uninst.exe /S" />
	</package>	

	
	<package
		id="flash-player-firefox"
		name="Flash Player (for Firefox, Mozilla, Netscape, Opera, Compuserve)"
		revision="1"
		reboot="false"
		priority="1">

		<depends
			package-id="firefox" />

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\Mozilla Firefox\plugins\NPSWF32.dll" />

		<install
			cmd="%PACKAGES%\flash-player-firefox\install_flash_player.exe /sp- /silent /norestart" />
			
		<upgrade
			cmd="%PACKAGES%\flash-player-firefox\install_flash_player.exe /sp- /silent /norestart" />

		<remove
			cmd="%PACKAGES%\flash-player-firefox\uninstall_flash_player.exe /sp- /silent /norestart" />
	</package>
	

	<package
		id="gaim"
		name="GAIM"
		revision="1"
		reboot="false"
		priority="1" >
	<depends
			package-id="gtk" />
			
		<check
			type="registry"
			condition="exists"
			path="HKLM\SOFTWARE\gaim" />

		<install
			cmd="%PACKAGES%\gaim\gaim-2.0.0beta4-no-gtk.exe /S" />

		<remove
			cmd="%PROGRAMFILES%\gaim\gaim-uninst.exe /s" />

		<upgrade
			cmd="" />
	</package>


	
	<package
		id="gdi+"
		name="GDI+"
		revision="1"
		reboot="false"
		priority="1">

		<install
			cmd="%PACKAGES%\gdi+\gdiplus_dnld.exe" />

	</package>

	

	<package
		id="gnupg"
		name="GnuPG"
		revision="1"
		reboot="false"
		priority="1">

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\GNU\GnuPG\gpg.exe" />

		<install
			cmd="%PACKAGES%\gnupg\gnupg-w32cli-1.4.5.exe /S" />

		<upgrade
			cmd="%PACKAGES%\gnupg\gnupg-w32cli-1.4.5.exe /S" />

			<remove
			cmd="%PROGRAMFILES%\GNU\GnuPG\uninst-gnupg.exe /S" />
	</package>

	
	
	<package
		id="gimp"
		name="The GIMP"
		revision="1"
		reboot="false"
		priority="1">

		<depends
			package-id="gtk" />

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\GIMP\bin\gimp-2.2.exe" />

		<install
			cmd='%PACKAGES%\gimp\gimp-2.2.12-i586-setup.exe SP- /SILENT /NORESTART /DIR="%PROGRAMFILES%\gimp"' />
			<!-- GIMP defaults to a version specific ish program directory, i.e. GIMP 2.2 goes in '%PROGRAMFILES%\GIMP 2.0' -->

		<upgrade
			cmd='%PACKAGES%\gimp\gimp-2.2.12-i586-setup.exe SP- /SILENT /NORESTART /DIR="%PROGRAMFILES%\gimp"' />

			<remove
			cmd="%PROGRAMFILES%\gimp\unins000.exe /sp- /silent /nocancel /norestart /log" />
	</package>


	<package
		id="gimp-help"
		name="The GIMP help files"
		revision="1"
		reboot="false"
		priority="1">

		<depends
			package-id="gimp" />

		<!-- gimp-help doesn't put itself in Add/Remove programs -->
		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\GIMP\share\gimp\2.0\help\images\callouts\1.png" />

		<install
			cmd="%PACKAGES%\gimp-help\gimp-help-2-0.10-setup.exe SP- /SILENT /NORESTART" />

		<upgrade
			cmd="%PACKAGES%\gimp-help\gimp-help-2-0.10-setup.exe SP- /SILENT /NORESTART" />

		<!-- GIMP-Help seems not to have an uninstaller; it is removed when GIMP is removed, but is that enough? -->

		</package>


	<package
		id="gtk"
		name="GTK"
		revision="1"
		reboot="false"
		priority="1">

		<check
			type="file"
			condition="exists"
			path="%COMMONPROGRAMFILES%\GTK\2.0\bin\libgtk-win32-2.0-0.dll" />

		<install
			cmd="%PACKAGES%\gtk\gtk+-2.8.18-setup-1.exe /sp- /silent /nocancel /norestart /log" />

		<upgrade
			cmd="%PACKAGES%\gtk\gtk+-2.8.18-setup-1.exe /sp- /silent /nocancel /norestart /log" />

		<remove
			cmd="%COMMONPROGRAMFILES%\GTK\2.0\unins000.exe /silent /norestart /log" />
	</package>

	<package 
		id="infra-recorder" 
		name="Infra Recorder" 
		revision="1" 
		reboot="false" 
		priority="1">

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\Infra Recorder\InfraRecorder.exe" />
			
		<install
			cmd="%PACKAGES%\infra-recorder\ir031.exe /S" />

		<upgrade
			cmd="%PACKAGES%\infra-recorder\ir031.exe /S" />

		<remove
			cmd="%PROGRAMFILES%\Infra Recorder\uninstall.exe /S" />
	</package>

	<package 
		id="inkscape" 
		name="Inkscape" 
		revision="1"
		reboot="false" 
		priority="1">

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\inkscape\inkscape.exe" />
			<!-- Inkscape doesn"t use the registry atall -->

		<install
			cmd="%PACKAGES%\inkscape\Inkscape-0.44.1-1.win32.exe /S" />

		<upgrade
			cmd="%PACKAGES%\inkscape\Inkscape-0.44.1-1.win32.exe /S" />

		<remove
			cmd="%PROGRAMFILES%\Inkscape\uninst.exe /S" />
	</package>


	
	<package
		id="irfanview"
		name="IrfanView"
		revision="1"
		reboot="false"
		priority="1">

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\IrfanView\i_view32.exe" />

		<install
			cmd="%PACKAGES%\irfanview\iview398.exe /silent /desktop=1 /thumbs=0 /group=1 /allusers=1 /assoc=1" />
		<!-- /assoc=1 associates images only;
		/thumbs=0 doesn't put the thumbnails icon on the desktop -->
		<!-- overwrite the INI file so that user settings are saved in their %APPDATA% directory
		<install
			cmd="cmd /c copy /y "%PACKAGES%\irfanview\i_view32.ini" "%PROGRAMFILES%\Irfanview\" /> -->

		<upgrade
			cmd="%PACKAGES%\irfanview\iview398.exe /silent /desktop=1 /thumbs=0 /group=1 /allusers=1 /assoc=1" />
			
		<remove
			cmd="%PROGRAMFILES%\IrfanView\iv_uninstall.exe /silent" />
	</package>

	
	
	<package
		id="irfanview-plugins"
		name="IrfanView plugins"
		revision="1"
		reboot="false"
		priority="1">

		<depends
			package-id="irfanview" />

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\IrfanView\Plugins\JPEG2000.dll" />
		<!-- Note that I think the removal of Irfanview will remove this too -->

		<install
			cmd="%PACKAGES%\irfanview-plugins\irfanview_plugins_398.exe /silent" />
		<!-- /assoc=1 associates images only;
		/thumbs=0 doesn't put the thumbnails icon on the desktop -->
		<!-- overwrite the INI file so that user settings are saved in their %APPDATA% directory
		<install
			cmd="cmd /c copy /y "%PACKAGES%\irfanview\i_view32.ini" "%PROGRAMFILES%\Irfanview\" /> -->

		<upgrade
			cmd="%PACKAGES%\irfanview-plugins\irfanview_plugins_398.exe /silent" />

		<remove
			cmd="%PROGRAMFILES%\IrfanView\iv_uninstall.exe /silent" />
	</package>


	<package
		id="kompozer"
		name="KompoZer"
		revision="1"
		priority="1"
		reboot="false">

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\KompoZer\kompozer.exe" />

		<install
			cmd="%PACKAGES%\kompozer\kompozer-077-win32.exe /sp- /silent /nocancel /norestart /log" />

		<upgrade
			cmd="%PACKAGES%\kompozer\kompozer-077-win32.exe /sp- /silent /nocancel /norestart /log" />

		<remove
			cmd="%PROGRAMFILES%\kompozer\unins000.exe /silent /log /norestart" />
	</package>

	

	<package
		id="lightning"
		name="Lightning"
		revision="1"
		reboot="false"
		priority="1">

		<depends
			package-id="thunderbird" />

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\Mozilla Thunderbird\extensions\{e2fda1a4-762b-4020-b5ad-a41df1933103}\components\lightning.js" />

		<install
			cmd='cmd /c "IF NOT EXIST "%PROGRAMFILES%\Mozilla Thunderbird\extensions\{e2fda1a4-762b-4020-b5ad-a41df1933103}" mkdir "%PROGRAMFILES%\Mozilla Thunderbird\extensions\{e2fda1a4-762b-4020-b5ad-a41df1933103}""' />

		<install
			cmd='"%WPKGROOT%\tools\unzip" -o "%PACKAGES%\lightning\lightning-0.3.win32.xpi" -d "%PROGRAMFILES%\Mozilla Thunderbird\extensions\{e2fda1a4-762b-4020-b5ad-a41df1933103}"' />

<!-- 		<install
			cmd='cmd /c ""%WPKGROOT%\tools\unzip" -o "%PACKAGES%\lightning\lightning-0.3rc2.win32.xpi" -d "%PROGRAMFILES%\Mozilla Thunderbird\extensions\{e2fda1a4-762b-4020-b5ad-a41df1933103}""' />
 -->
		<upgrade
			cmd='cmd /c "IF NOT EXIST "%PROGRAMFILES%\Mozilla Thunderbird\extensions\{e2fda1a4-762b-4020-b5ad-a41df1933103}" mkdir "%PROGRAMFILES%\Mozilla Thunderbird\extensions\{e2fda1a4-762b-4020-b5ad-a41df1933103}""' />

		<upgrade
			cmd='cmd /c ""%WPKGROOT%\tools\unzip" -o "%PACKAGES%\lightning\lightning-0.3.win32.xpi" -d "%PROGRAMFILES%\Mozilla Thunderbird\extensions\{e2fda1a4-762b-4020-b5ad-a41df1933103}""' />
	</package>
	
	
	<package
		id="myodbc"
		name="MyODBC connector"
		revision="1"
		reboot="false"
		priority="1" >

		<check
			type="uninstall"
			condition="exists"
			path="MySQL Connector/ODBC 3.51" />

		<install
			cmd='msiexec /qb /package "%PACKAGES%\myodbc\mysql-connector-odbc-3.51.12-win32.msi" /qr' />

		<upgrade
			cmd='msiexec /qb /package "%PACKAGES%\myodbc\mysql-connector-odbc-3.51.12-win32.msi" /qr' />

		<remove
			cmd="MsiExec.exe /qb /uninstall {0CB3C535-1171-4A20-B549-E2CB5DEB9723}" >
				</remove>
	</package>
	<!--  /S %windir%\system32\myodbc3_install.log -->


	<package
		id="notepad++"
		name="Notepad++"
		revision="1"
		reboot="false"
		priority="1">

		<check
			type="uninstall"
			condition="exists"
			path="Notepad++" />

		<install
			cmd="%PACKAGES%\notepad++\npp.3.9.Installer.exe /S" />

		<upgrade
			cmd="%PACKAGES%\notepad++\npp.3.9.Installer.exe /S" />

		<remove
			cmd="%PROGRAMFILES%\Notepad++\uninstall.exe /S" />
	</package>


	<package
		id="openoffice" 
		name="OpenOffice" 
		revision="1"
		reboot="false" 
		priority="1">

		<depends
			package-id="sun-jre" />

		<check
			type="uninstall"
			condition="exists"
			path="OpenOffice.org 2.0" />

		<install
			cmd='msiexec /qb /package "%PACKAGES%\openoffice\openofficeorg20.msi" ALLUSERS=1 SELECT_WORD=1 SELECT_EXCEL=1 SELECT_POWERPOINT=1' />

		<upgrade
			cmd='msiexec /qb /uninstall "%PACKAGES%\openoffice\openofficeorg20.msi" ALLUSERS=1 SELECT_WORD=1 SELECT_EXCEL=1 SELECT_POWERPOINT=1' />

		<remove
			cmd="msiexec /qb /uninstall {686BB230-DE5B-44F4-8DB0-4F9BEE7310F7}" />
	</package>



	<package
		id="picasa"
		name="Picasa"
		revision="1"
		reboot="false"
		priority="1">

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\picasa\Picasa2.exe" />

		<install
			cmd='%PACKAGES%\picasa\setup.exe /S /D=%PROGRAMFILES%\picasa '/>
		<!-- Don't use quotes like this or the option will be ignored: /D="%PROGRAMFILES%\picasa" -->

		<upgrade
			cmd='%PACKAGES%\picasa\setup.exe /S /D=%PROGRAMFILES%\picasa '/>

		<remove
			cmd="%PROGRAMFILES%\picasa\Uninstall.exe /S" />
	</package>

	
	
	<package
		id="putty"
		name="Putty"
		revision="1"
		priority="1"
		reboot="false">

		<check
			type="uninstall"
			condition="exists"
			path="PuTTY version 0.58" />

		<install
			cmd="%PACKAGES%\putty\putty-0.58-installer.exe /sp- /silent /nocancel /norestart /log" />

		<upgrade
			cmd="%PACKAGES%\putty\putty-0.58-installer.exe /sp- /silent /nocancel /norestart /log" />

		<remove
			cmd="%PROGRAMFILES%\PuTTY\unins000.exe /silent /log /norestart" />
<!-- DOES IT NEED A RESTART BEFORE IS DEALT WITH PROPERLY? asks if we want to remove saved sessions -->
	</package>



	<package 
		id="thunderbird" 
		name="Mozilla Thunderbird" 
		revision="1"
		reboot="false" 
		priority="1">

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\Mozilla Thunderbird\thunderbird.exe"/>

		<install
			cmd="%PACKAGES%\Thunderbird\Thunderbird Setup 1.5.0.7.exe -ms" />

		<upgrade
			cmd="%PACKAGES%\Thunderbird\Thunderbird Setup 1.5.0.7.exe -ms" />

		<remove
			cmd="%PROGRAMFILES%\Mozilla Thunderbird\uninstall\uninstall.exe -ms" >
			<exit
				code="20" /></remove>

			<!-- Thunderbird uninstalled but returned result 20 -->
	</package>

	
	<package
		id="thunderbird-spellcheck-dictionary-en-gb"
		name="Thunderbird spellchecker dictionary English (GB)"
		revision="1"
		reboot="false"
		priority="1">

		<depends
			package-id="thunderbird" />

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\Mozilla Thunderbird\components\myspell\en-GB.dic" />

		<install
			cmd='cmd /c "copy "%PACKAGES%\myspell-dictionaries\en_GB\en_GB.aff" "%PROGRAMFILES%\Mozilla Thunderbird\components\myspell\en-GB.aff""' />

		<install
			cmd='cmd /c "copy "%PACKAGES%\myspell-dictionaries\en_GB\en_GB.dic" "%PROGRAMFILES%\Mozilla Thunderbird\components\myspell\en-GB.dic""' />

		<upgrade
			cmd='cmd /c "copy "%PACKAGES%\myspell-dictionaries\en_GB\en_GB.aff" "%PROGRAMFILES%\Mozilla Thunderbird\components\myspell\en-GB.aff""' />

		<upgrade
			cmd='cmd /c "copy "%PACKAGES%\myspell-dictionaries\en_GB\en_GB.dic" "%PROGRAMFILES%\Mozilla Thunderbird\components\myspell\en-GB.dic""' />
	</package>


	<package
		id="windows-media-player-9"
		name="Windows Media Player 9" >

<!-- Windows 2000 came with Media Player 7.
The latest available version for Windows 2000 is 9.
Windows XP SP2 includes version 9. -->

		<check
			type="file"
			condition="versiongreaterorequal"
			path="%PROGRAMFILES%\Windows Media Player\wmplayer.exe"
			value="9.0.0.0" />

		<install
			cmd="%PACKAGES%\windows-media-player-9\mp9setup.exe /Q /R:N /C:'setup_wm.exe /Q /R:N /DisallowSystemRestore /NoPID /SetWMPAsDefault'">

			<exit
				code="194"
				reboot="false" />

			<exit
				code="3010"
				reboot="false" /></install>
	</package>






	<package 
		id="nero-burnrights" 
		name="Nero BurnRights" 
		revision="1" 
		reboot="false" 
		priority="1">

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\Ahead\NeroBurnRights\NeroBurnRights.exe" />

<!--
		this doesn't work, don't know why:
		<check
			type="registry"
			condition="exists"
			path="HKLM\SOFTWARE\Ahead\Nero BurnRights" />
-->
		<install
			cmd='%PACKAGES%\nero-burnrights\NeroBurnRightsInstaller.exe /silent /burnrights:all' />

		<upgrade
			cmd='%PACKAGES%\nero-burnrights\NeroBurnRightsInstaller.exe /silent /burnrights:all' />

		<remove
			cmd="%WINDIR%\UNNeroBurnRights.exe /uninstall /silent" />
			
	</package>

	
	<package
		id="scribus"
		name="Scribus"
		revision="1"
		reboot="false"
		priority="1">

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\Scribus\Scribus.exe" />

		<install
			cmd="%PACKAGES%\gdi+\install-gdi+.bat" />
		<!-- If this is Windows 2000, copy GDI+ DLL to Scribus program directory.
		If it doesn't already exist Scribus brings up a dialog window saying its not there asking if we want to download it. -->

		<install
			cmd="%PACKAGES%\scribus\scribus-1.3.3.4-win32-install.exe /S /D=%PROGRAMFILES%\Scribus" />

		<upgrade
			cmd='cmd /c "start /WAIT ""%PROGRAMFILES%\Scribus\uninst.exe" /S""' />
		<!-- Without uninstalling the previous version you'll be prompted to do so -->

		<upgrade
			cmd="%PACKAGES%\scribus\scribus-1.3.3.4-win32-install.exe /S /D=%PROGRAMFILES%\Scribus" />

		<remove
			cmd="%PROGRAMFILES%\Scribus\uninst.exe /S" />

		<remove
			cmd="del %WINDIR%\system32\gdiplus.dll" />
		</package>
	

	
	<package
		id="sun-jre"
		name="Sun Java Runtime Environment"
		revision="1"
		reboot="false"
		priority="1">

		<check
			type="registry"
			condition="exists"
			path="HKLM\SOFTWARE\JavaSoft\Java Runtime Environment\CurrentVersion" />

		<install
			cmd='%PACKAGES%\sun-jre\jre-1_5_0_08-windows-i586-p.exe /qb ADDLOCAL=jrecore IEXPLORER=1 MOZILLA=1 JAVAUPDATE=0 REBOOT=Suppress CUSTOM=1' />
<!-- I believe 1.5.0 update 6 worked with this, but the same thing brings up the explanation of installer options with update 8: 
%PACKAGES%\sun-jre\jre-1_5_0_08-windows-i586-p.exe /S/v"/qn ADDLOCAL=jrecore IEXPLORER=1 MOZILLA=1 JAVAUPDATE=0 REBOOT=Suppress CUSTOM=1
With update 6 though this silent install wasn't silent - JRE has you accept the licence, at which point you can also choose custom install; and you have to click on 'Finish'

/quiet and /passive don't give any response if there's an error and I think WPKG's errors in plain text might be ignored by users, so I'm trying /qb
-->

		<upgrade
			cmd='%PACKAGES%\sun-jre\jre-1_5_0_08-windows-i586-p.exe /qb ADDLOCAL=jrecore IEXPLORER=1 MOZILLA=1 JAVAUPDATE=0 REBOOT=Suppress CUSTOM=1' />

		<remove
			cmd='msiexec.exe /qb /uninstall {3248F0A8-6813-11D6-A77B-00B0D0150080}' />
	</package>


	<package
		id="vlc"
		name="Video LAN Client"
		revision="1"
		reboot="false"
		priority="1"> 

		<check
			type="uninstall"
			condition="exists"
			path="VideoLAN VLC media player 0.8.5" />

		<install
			cmd="%PACKAGES%\vlc\vlc-0.8.5-win32.exe /S" />

		<upgrade
			cmd="%PACKAGES%\vlc\vlc-0.8.5-win32.exe /S" />

		<remove
			cmd="%PROGRAMFILES%\VideoLAN\VLC\uninstall.exe /S" />
	</package>

	
	<package 
		id="wincvs"
		name="WinCVS"
		revision="1"
		priority="1"
		reboot="false">

		<check
			type="uninstall"
			condition="exists"
			path="WinCvs 2.0" />

		<!-- <install
			cmd="%PACKAGES%\wincvs\cvsnt_setup.exe /sp- /silent /nocancel /norestart /log" />
			don't need this, see install.txt in installer directory -->

		<install
			cmd="%PACKAGES%\wincvs\wincvs_setup.exe /sp- /silent /nocancel /norestart /log" />

		<upgrade
			cmd="%PACKAGES%\wincvs\wincvs_setup.exe /sp- /silent /nocancel /norestart /log" />

		<remove
			cmd="%PROGRAMFILES%\GNU\WinCvs 2.0\unins000.exe /silent /log /norestart" />

	</package>


	<package
		id="winscp"
		name="WinSCP"
		revision="1"
		priority="1"
		reboot="false">

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\WinSCP3\WinSCP3.exe" />

		<install
			cmd="%PACKAGES%\winscp\winscp382setupintl2 /sp- /silent /nocancel /norestart /log" />

		<upgrade
			cmd="%PACKAGES%\winscp\winscp382setupintl2 /sp- /silent /nocancel /norestart /log" />

		<remove
			cmd="%PROGRAMFILES%\WinSCP3\unins000.exe /silent /log /norestart" />
<!-- says 'do you want to cleanup data stored by the application on this computer?' -->
<!-- the English installer is called winscp382setup.exe -->
	</package>


	<package
		id="x-chat"
		name="X-Chat"
		revision="1"
		reboot="false"
		priority="1">

		<check
			type="file"
			condition="exists"
			path="%PROGRAMFILES%\X-Chat\xchat.exe" />

		<install
			cmd='%PACKAGES%\X-Chat\xchat-2.6.6-1.exe /sp- /silent /nocancel /norestart /log /DIR="%PROGRAMFILES%\X-Chat"' />

		<upgrade
			cmd='%PACKAGES%\X-Chat\xchat-2.6.6-1.exe /sp- /silent /nocancel /norestart /log /DIR="%PROGRAMFILES%\X-Chat"' />

		<remove
			cmd="%PROGRAMFILES%\X-Chat\unins000.exe /silent /log /norestart" />
	</package>


	<package
		id="xsane"
		name="XSane"
		revision="1"
		reboot="false"
		priority="1">


		<check
			type="file"
			condition="exists"
			path="C:\sane\bin\xsane.exe" />

		<install
			cmd='cmd /c "IF NOT EXIST C:\sane mkdir C:\sane"' />

		<install
			cmd='cmd /c "copy "%PACKAGES%\xsane\xsane-win32-0.991.zip" "%TEMP%""' />
		<install
			cmd='cmd /c ""%WPKGROOT%\tools\unzip" -o "%TEMP%\xsane-win32-0.991.zip" -d C:\"' />

<!-- 		<install
			cmd='"%WPKGROOT%\tools\unzip" -o "%PACKAGES%\xsane\xsane-win32-0.991.zip" -d C:\' /> -->
<!-- BUG: The above hangs when done using xcopy on the uncompressed files, or using unzip; I've tried the above with and without CMD;
tried copying .zip to %TEMP% first and unzipping from there -->
		<upgrade
			cmd='cmd /c "IF NOT EXIST C:\sane mkdir C:\sane"' />

		<upgrade
			cmd='cmd /c ""%WPKGROOT%\tools\unzip" -o "%PACKAGES%\xsane\xsane-win32-0.991.zip" -d C:\"' />

		<remove
			cmd='cmd /c "rmdir /S /Q C:\sane\"' />
	</package>

</packages>

