[wpkg-users] How to uninstall previous versions

Nicolas Briche nbriche at free.fr
Sun Sep 28 14:10:34 CEST 2014


Hello all,

Le 2014-09-28 13:54, Marco Schmidt a écrit :
> Hello,
> 
> your question addresses two (nearly independent) problems.
> 1. uninstall ALL previous versions of libreoffice
> 2. can this be done with wpkg
> 
> For a complete answer of (1) it is best to ask in a libreoffice support 
> forum.

 From experience, the LibreOffice installer removes all previous 
instances of itself before installing.

However, and here's the trick, it doesn't remove _Open_Office, which is 
why my Libreoffice package looks like this:

<package
id="libreoffice"
name="LibreOffice"
revision="%PKG_REVISION%"
priority="70">

<variable name="PKG_REVISION" value="4.3.1" />
<variable name="LO_DICT_LANGUAGES" 
value='gm_r_ex_Dictionary_Af,gm_r_ex_Dictionary_An,gm_r_ex_Dictionary_Ar,gm_r_ex_Dictionary_Be,gm_r_ex_Dictionary_Bg,gm_r_ex_Dictionary_Bn,gm_r_ex_Dictionary_Br,gm_r_ex_Dictionary_Ca,gm_r_ex_Dictionary_Cs,gm_r_ex_Dictionary_Da,gm_r_ex_Dictionary_De,gm_r_ex_Dictionary_El,gm_r_ex_Dictionary_En,gm_r_ex_Dictionary_Es,gm_r_ex_Dictionary_Et,gm_r_ex_Dictionary_Gd,gm_r_ex_Dictionary_Gl,gm_r_ex_Dictionary_Gu,gm_r_ex_Dictionary_He,gm_r_ex_Dictionary_Hi,gm_r_ex_Dictionary_Hr,gm_r_ex_Dictionary_Hu,gm_r_ex_Dictionary_It,gm_r_ex_Dictionary_Lt,gm_r_ex_Dictionary_Lv,gm_r_ex_Dictionary_Ne,gm_r_ex_Dictionary_Nl,gm_r_ex_Dictionary_No,gm_r_ex_Dictionary_Oc,gm_r_ex_Dictionary_Pl,gm_r_ex_Dictionary_Pt_Pt,gm_r_ex_Dictionary_Ro,gm_r_ex_Dictionary_Ru,gm_r_ex_Dictionary_Si,gm_r_ex_Dictionary_Sk,gm_r_ex_Dictionary_Sl,gm_r_ex_Dictionary_Sr,gm_r_ex_Dictionary_Sv,gm_r_ex_Dictionary_Te,gm_r_ex_Dictionary_Th,gm_r_ex_Dictionary_Uk,gm_r_ex_Dictionary_Vi,gm_r_ex_Dictionary_Zu' 
/>
<variable name="LO_REMOVE_OPTIONS" 
value='REMOVE=%LO_DICT_LANGUAGES%,gm_o_Onlineupdate' />
<variable name="LO_PARAMETERS" value='/l* c:\libreoffice_install_log.txt 
COMPANYNAME="CHP" USERNAME="" ISCHECKFORPRODUCTUPDATE=0 
CREATEDESKTOPLINK=0 ADDLOCAL=ALL UI_LANGS=fr REGISTER_ALL_MSO_TYPES=0 
RebootYesNo=No %LO_REMOVE_OPTIONS%' />

<check type="uninstall" condition="versiongreaterorequal" 
path="LibreOffice .+" value="%PKG_REVISION%" />

<commands>

	<command type="install" cmd='cscript %CHECKPROC% soffice.bin 
soffice.exe' />
	<command type="install" cmd='msiexec /qn 
/X{419805D6-75A0-4981-BC8F-9FF97EC6B03A}'><exit code='0' /><exit 
code='1605' /></command> <!-- OpenOffice 2.2 v9161 -->
	<!-- Manque: OpenOffice 2.2 v9134 -->
	<command type="install" cmd='msiexec /qn 
/X{417E90DF-A9C4-43C4-90D9-FD7F107B68DB}'><exit code='0' /><exit 
code='1605' /></command> <!-- OpenOffice 2.3 v9221 -->
	<command type="install" cmd='msiexec /qn 
/X{331DFBF7-734D-4545-8A9D-48CB5D73AF07}'><exit code='0' /><exit 
code='1605' /></command> <!-- OpenOffice 2.3 v9238 -->
	<command type="install" cmd='msiexec /qn 
/X{2A1AA9CF-2E7D-4235-BDAB-8FA4291DD5D8}'><exit code='0' /><exit 
code='1605' /></command> <!-- OpenOffice 2.4 v9286 -->
	<command type="install" cmd='msiexec /qn 
/X{6860B340-530D-46B3-91F8-1AE1F70F7C33}'><exit code='0' /><exit 
code='1605' /></command> <!-- OpenOffice 3.0 v9358 -->
	<command type="install" cmd='msiexec /qn 
/X{1572F66F-F9AD-4D45-B0D2-0F45A0D5A0F6}'><exit code='0' /><exit 
code='1605' /></command> <!-- OpenOffice 3.0 v9379 -->
	<command type="install" cmd='msiexec /qn 
/X{B2E581DB-C4DD-432C-AC84-ED761AC056BC}'><exit code='0' /><exit 
code='1605' /></command> <!-- OpenOffice 3.1 v9399, v9420 -->
	<command type="install" cmd='msiexec /qn 
/X{97B3824E-B2D2-4C49-A860-BCA56F10B040}'><exit code='0' /><exit 
code='1605' /></command> <!-- OpenOffice 3.2 v9483 -->
	<command type="install" cmd='msiexec /qn 
/X{7E0610A2-E336-40B3-B685-C4905E97EC9A}'><exit code='0' /><exit 
code='1605' /></command> <!-- OpenOffice 3.3 v9567 -->
	<command type="install" cmd='msiexec /qn /norestart /I 
"%SOFTWARE%\Outils_Bureautique\libreoffice\LibreOffice_%PKG_REVISION%_Win_x86.msi" 
%LO_PARAMETERS%'>
		<exit code="3010" reboot="false" />
	</command>

	<command type="upgrade" include='install' />

	<command type="remove" cmd='msiexec /qn /X 
"%SOFTWARE%\Outils_Bureautique\libreoffice\LibreOffice_%PKG_REVISION%_Win_x86.msi"' 
/>
</commands>


</package>




More information about the wpkg-users mailing list