Hello,
I have to fix a bug in a wix project but i don't know much about that
technology and there is no one to help me anymore in my team.
Here is the bug :
The asp.net framework in my default web site in iis is defined at 1.1.
When I'm creating a new virtual directory, I need it to be in 2.0 framework.
I've read that it could be done with those lines :
<!-- Ajout de la version 2.0.50727 d'ASP.NET à l'alias binovaliclient dans
IIS-->
<CustomAction Id="MakeWepApp20" Directory="binovaliclient"
ExeCommand="C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\aspnet_regiis.exe
-norestart -s W3SVC/1/ROOT/binovaliclient" Return="check"/>
<InstallExecuteSequence>
<Custom Action="MakeWepApp20" After="InstallFinalize">
FRAMEWORKDIR AND NOT Installed
</Custom>
</InstallExecuteSequence>
But it seems it's not called or doesn't work. When I check the value in IIS,
the target framework is 1.1 and not 2.0.
If necessary here is all the code :
<?xml version="1.0" encoding="utf-8"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"
xmlns:iis="http://schemas.microsoft.com/wix/IIsExtension"
xmlns:util="http://schemas.microsoft.com/wix/UtilExtension"
xmlns:netfx="http://schemas.microsoft.com/wix/NetFxExtension"
xmlns:wixvs="http://schemas.microsoft.com/wix/WixVSExtension">
<?define NetVersion = 2.0.50727 ?>
<Product Id="*" Name="Ovali Client $(var.ProductVersion)" Language="1033"
Version="$(var.ProductVersion)" Manufacturer="Orange Business Services"
UpgradeCode="3C6E5A3D-4127-4F3F-9BE7-C1F2939C959C">
<Package Description="OvaliClient executable" Comments="Executable of
OvaliClient" InstallerVersion="200" Compressed="yes" />
<!--Liste des prérequis-->
<Condition Message="You need to be an administrator to install this
product.">Privileged</Condition>
<Condition Message="ASP.NET $(var.NetVersion) version does not
exist">ASPNETVERSION</Condition>
<Condition Message="This application requires .NET Framework
$(var.NetVersion)">Installed OR NETFRAMEWORK20</Condition>
<Condition Message="This application requires J# redistributable
package 2.0 (x64 on 64 bits machines)">Installed OR JSHARPINSTALLED</Condition>
<Condition Message="IIS must be installed">Installed OR
IIS_MAJOR_VERSION</Condition>
<Condition Message="Your install directory does not
exist">DIREXIST</Condition>
<Media Id="1" Cabinet="simple.cab" EmbedCab="yes" />
<!--Test de l'existence du répertoire d'installation (d:\wwwroot par
défaut)-->
<Property Id="DIREXIST">
<DirectorySearch Id="CheckDir" Path="[INSTALLDIR]" Depth="0" />
</Property>
<!-- TO/2011.021697-A.01 Determine the .Net framework root directory
from the registry-->
<Property Id="FRAMEWORKROOT">
<RegistrySearch Id="FrameworkRootDir" Root="HKLM"
Key="SOFTWARE\Microsoft\.NETFramework" Type="directory" Name="InstallRoot"
Win64='yes' />
</Property>
<CustomAction Id="setFRAMEWORKDIR" Property="FRAMEWORKDIR"
Value="[FRAMEWORKROOT]\v$(var.NetVersion)" />
<!--Test de l'existence de la version d'ASP.NET pour les alias IIS-->
<Property Id="ASPNETVERSION">
<DirectorySearch Id="CheckASPNETversion" Path="[FRAMEWORKDIR]"
Depth="0" />
</Property>
<!--Test de l'installation de IIS-->
<Property Id="IIS_MAJOR_VERSION">
<RegistrySearch Id="CheckIISVersion" Root="HKLM"
Key="SOFTWARE\Microsoft\InetStp" Name="MajorVersion" Type="raw" />
</Property>
<!--Création de l'arborescence de l'installation-->
<Directory Id="TARGETDIR" Name="SourceDir">
<Directory Id="INSTALLDIR" Name="wwwRoot">
<Directory Id="OvaliClient" Name="OvaliClient">
<Directory Id="binovaliclient" Name="binovaliclient">
<Component Id="OvaliValidator.asmx" DiskId="1"
Guid="995DE7BD-E6D9-4B4F-A332-61B046119DAB">
<File Id="OvaliValidator.asmx"
Name="OvaliValidator.asmx" Source="..\..\..\binovaliclient\OvaliValidator.asmx"
/>
<RemoveFile Id="removeOvaliValidator.aspx"
Name="OvaliValidator.asmx" On="uninstall" />
</Component>
<Component Id="PrecompiledApp.config" DiskId="1"
Guid="A8F94541-53CF-42A6-B688-5B1C0B198F5D">
<File Id="PrecompiledApp.config"
Name="PrecompiledApp.config"
Source="..\..\..\binovaliclient\PrecompiledApp.config" />
<RemoveFile Id="removePrecompiledApp.config"
Name="PrecompiledApp.config" On="uninstall" />
</Component>
<Component Id="web.config" DiskId="1"
Guid="D368A2CA-D0A7-4E48-8B0C-3C68E6225AC3">
<File Id="web.config" Name="web.config"
Source="..\..\..\binovaliclient\web.config" />
<RemoveFile Id="removeweb.config" Name="web.config"
On="uninstall" />
<!--Paramètrage des fichiers de config-->
<util:XmlFile Id='XmlFile_1'
File='[INSTALLDIR]OvaliClient\binovaliclient\web.config' Action='setValue'
Name='value' Value='[INSTALLDIR]Log\OvaliClient\OvaliError'
ElementPath='//configuration/log4net/appender/file' Sequence='1' />
<util:XmlFile Id='XmlFile_2'
File='[INSTALLDIR]OvaliClient\binovaliclient\web.config' Action='setValue'
Name='path' Value='[INSTALLDIR]OvaliClient\Donnees\Enlecture\Xsd\request.xsd'
ElementPath='//configuration/ovali/schemas/add' Sequence='2' />
<util:XmlFile Id='XmlFile_3'
File='[INSTALLDIR]OvaliClient\binovaliclient\web.config' Action='setValue'
Name='value'
Value='[INSTALLDIR]OvaliClient\Donnees\Enlecture\Xml\variables.xml'
ElementPath='//configuration/appSettings/add[\[]@key="FichierParameter"[\]]'
Sequence='3' />
<util:XmlFile Id='XmlFile_4'
File='[INSTALLDIR]OvaliClient\binovaliclient\web.config' Action='setValue'
Name='value' Value='[INSTALLDIR]OvaliClient\Donnees\Enlecture\Xml\catalog.xml'
ElementPath='//configuration/appSettings/add[\[]@key="Catalog_File_Path"[\]]'
Sequence='4' />
<!--Fin paramètrage des fichiers de config-->
</Component>
<Directory Id="bin" Name="bin">
<Component Id="App_Code.compiled" DiskId="1"
Guid="647E23A2-918A-4CB2-A232-6D0FC82062FA">
<File Id="App_Code.compiled"
Name="App_Code.compiled" Source="..\..\..\binovaliclient\bin\App_Code.compiled"
/>
<RemoveFile Id="removeApp_Code.compiled"
Name="App_Code.compiled" On="uninstall" />
</Component>
<Component Id="App_Code.dll" DiskId="1"
Guid="AEACDCB8-DCB6-45E0-B217-F77786F00294">
<File Id="App_Code.dll" Name="App_Code.dll"
Source="..\..\..\binovaliclient\bin\App_Code.dll" />
<RemoveFile Id="removeApp_Code.dll"
Name="App_Code.dll" On="uninstall" />
</Component>
<Component Id="App_global.asax.compiled" DiskId="1"
Guid="E09FD925-FB4F-4312-A2B0-A47021EBEC38">
<File Id="App_global.asax.compiled"
Name="App_global.asax.compiled"
Source="..\..\..\binovaliclient\bin\App_global.asax.compiled" />
<RemoveFile Id="removeApp_global.asax.compiled"
Name="App_global.asax.compiled" On="uninstall" />
</Component>
<Component Id="App_global.asax.dll" DiskId="1"
Guid="B0AC5C2E-1723-4697-B6E4-8C2F9DF221CA">
<File Id="App_global.asax.dll"
Name="App_global.asax.dll"
Source="..\..\..\binovaliclient\bin\App_global.asax.dll" />
<RemoveFile Id="removeApp_global.asax.dll"
Name="App_global.asax.dll" On="uninstall" />
</Component>
<Component Id="com.equant.flsub.dll" DiskId="1"
Guid="E50279B4-63F8-4B98-9C34-B0B3BB73AF25">
<File Id="com.equant.flsub.dll"
Name="com.equant.flsub.dll"
Source="..\..\..\binovaliclient\bin\com.equant.flsub.dll" />
<RemoveFile Id="removecom.equant.flsub.dll"
Name="com.equant.flsub.dll" On="uninstall" />
</Component>
<Component Id="log4net.dll" DiskId="1"
Guid="BDFD3471-6122-4F76-B1A3-A353A6C482BB">
<File Id="log4net.dll" Name="log4net.dll"
Source="..\..\..\binovaliclient\bin\log4net.dll" />
<RemoveFile Id="removelog4net.dll"
Name="log4net.dll" On="uninstall" />
</Component>
<Component Id="Dirbin" DiskId="1"
Guid="B5D1681B-EC06-4f7f-AAD0-38853F38ABF5">
<CreateFolder/>
<RemoveFolder Id='bin' On='uninstall' />
</Component>
</Directory>
<!-- TO/2011.021697-A.01 -->
<!-- Create and configure the virtual directory and
application. -->
<Component Id='C_VirtualDirComponent'
Guid="14C1308F-2EBB-4341-98A4-8796C706EE23" Permanent='no' >
<iis:WebAppPool Id="OvaliClientAppPool"
Name="OvaliClient" Identity="networkService" />
<iis:WebVirtualDir Id="VirtualDir"
Alias="[TARGETVDIR]" Directory="binovaliclient" WebSite="DefaultWebSite"
DirProperties="WebVirtualDirProperties" >
<iis:WebApplication Id='WebApplication'
Name='OvaliClient' WebAppPool='OvaliClientAppPool'>
<!-- Required to run the application under
the .net 2.0 framework -->
<iis:WebApplicationExtension Extension="*"
CheckPath="no" Script="yes" Executable="[FRAMEWORKDIR]\aspnet_isapi.dll"
Verbs="GET,HEAD,POST" />
</iis:WebApplication>
</iis:WebVirtualDir>
<CreateFolder />
</Component>
<!-- TO/2011.021697-A.01 Fin -->
<Component Id="Dirbinovaliclient" DiskId="1"
Guid="F14C7EFC-0973-4b2b-8CA1-239566293918">
<CreateFolder/>
<RemoveFolder Id='binovaliclient' On='uninstall' />
</Component>
</Directory>
<!--Fin Directory binovaliclient-->
<Directory Id="Donnees" Name="Donnees">
<!--Gestion des permissions "read files" sur le
répertoire-->
<Component Id ="AclComponent"
Guid="17100DFD-2169-45cb-A8EB-9AF2E51CE276">
<CreateFolder>
<util:PermissionEx User="ASPNET" Read="yes"
GenericRead="yes" ReadAttributes="yes" ReadPermission="yes" />
</CreateFolder>
</Component>
<!--Fin de Gestion des permissions "read files"-->
<Directory Id="EnLecture" Name="EnLecture">
<Directory Id="Xml" Name="Xml">
<Component Id="catalog.xml" DiskId="1"
Guid="B9868EAD-C1E6-4C5D-B727-46FBB9366BE2">
<File Id="catalog.xml" Name="catalog.xml"
Source="..\..\..\Donnees\EnLecture\Xml\catalog.xml" />
<RemoveFile Id="removecatalog.xml"
Name="catalog.xml" On="uninstall" />
</Component>
<Component Id="variables.xml" DiskId="1"
Guid="A7A1BFF1-0010-419B-B5B8-2ADF62604346">
<File Id="variables.xml"
Name="variables.xml" Source="..\..\..\Donnees\EnLecture\Xml\variables.xml" />
<RemoveFile Id="removevariables.xml"
Name="variables.xml" On="uninstall" />
</Component>
<Component Id="DirXml" DiskId="1"
Guid="C16C9744-6AB9-4596-9E8A-8ACA20662FA0">
<CreateFolder/>
<RemoveFolder Id='Xml' On='uninstall' />
</Component>
</Directory>
<Directory Id="Xsd" Name="Xsd">
<Component Id="request.xsd" DiskId="1"
Guid="803064E9-EA4B-4F76-B5F0-24EAB59D06F7">
<File Id="request.xsd" Name="request.xsd"
Source="..\..\..\Donnees\EnLecture\Xsd\request.xsd" />
<RemoveFile Id="removerequest.xsd"
Name="request.xsd" On="uninstall" />
</Component>
<Component Id="result.xsd" DiskId="1"
Guid="9D951337-DD59-4431-AC69-533A07244230">
<File Id="result.xsd" Name="result.xsd"
Source="..\..\..\Donnees\EnLecture\Xsd\result.xsd" />
<RemoveFile Id="removeresult.xsd"
Name="result.xsd" On="uninstall" />
</Component>
<Component Id="DirXsd" DiskId="1"
Guid="6FDE9CA8-A409-4b98-BDF1-2C4DBF746612">
<CreateFolder/>
<RemoveFolder Id='Xsd' On='uninstall' />
</Component>
</Directory>
<Component Id="DirEnLecture" DiskId="1"
Guid="F1FA8314-8069-4272-933C-F7E19367EB51">
<CreateFolder/>
<RemoveFolder Id='EnLecture' On='uninstall' />
</Component>
</Directory>
<Component Id="DirDonnees" DiskId="1"
Guid="E132DC88-A1C2-4823-B700-DF62B11C280B">
<CreateFolder/>
<RemoveFolder Id='Donnees' On='uninstall' />
</Component>
</Directory>
<!--Fin Directory Donnees-->
<Component Id="DirOvaliClient" DiskId="1"
Guid="63E8BA70-25B1-4522-9DE1-6B1D98325208">
<CreateFolder/>
<RemoveFolder Id='OvaliClient' On='uninstall' />
</Component>
</Directory>
<!--Fin Directory OvaliClient-->
<Directory Id="log" Name="log">
<Directory Id="OvaliClient_log" Name="OvaliClient">
<!--Suppression de ce répertoire à la désinstallation-->
<Component Id="Compo_OvaliClient_log" DiskId="1"
Guid="B7E4671C-E02D-4c92-A22E-66A68267E61C">
<CreateFolder/>
<RemoveFolder Id='OvaliClient_log' On='uninstall' />
</Component>
</Directory>
<!--Fin Directory OvaliClient_log-->
</Directory>
<!--Fin Directory log-->
</Directory>
<!--Fin Directory INSTALLDIR-->
</Directory>
<!--Fin Directory TARGETDIR-->
<Feature Id="DefaultFeature" Title="Main Feature" Level="1">
<ComponentRef Id="OvaliValidator.asmx" />
<ComponentRef Id="PrecompiledApp.config" />
<ComponentRef Id="web.config" />
<ComponentRef Id="App_Code.compiled" />
<ComponentRef Id="App_Code.dll" />
<ComponentRef Id="App_global.asax.compiled" />
<ComponentRef Id="App_global.asax.dll" />
<ComponentRef Id="com.equant.flsub.dll" />
<ComponentRef Id="log4net.dll" />
<ComponentRef Id="C_VirtualDirComponent" />
<ComponentRef Id="catalog.xml" />
<ComponentRef Id="variables.xml" />
<ComponentRef Id="request.xsd" />
<ComponentRef Id="result.xsd" />
<ComponentRef Id="Compo_OvaliClient_log"/>
<ComponentRef Id="Dirbin"/>
<ComponentRef Id="Dirbinovaliclient"/>
<ComponentRef Id="DirXml"/>
<ComponentRef Id="DirXsd"/>
<ComponentRef Id="DirEnLecture"/>
<ComponentRef Id="DirDonnees"/>
<ComponentRef Id="DirOvaliClient"/>
<ComponentRef Id="AclComponent"/>
</Feature>
<UI />
<iis:WebDirProperties Id="WebVirtualDirProperties" Execute="no"
Script="yes" Read="yes" WindowsAuthentication="no" AnonymousAccess="yes" />
<!-- Web site is only created if it doesn't already exist -->
<iis:WebSite Id="DefaultWebSite" Description="Default Web Site">
<iis:WebAddress Id="AllAdresses" IP="*" Port="80" />
</iis:WebSite>
<!-- Ajout de la version 2.0.50727 d'ASP.NET à l'alias binovaliclient
dans IIS-->
<CustomAction Id="MakeWepApp20" Directory="binovaliclient"
ExeCommand="C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\aspnet_regiis.exe
-norestart -s W3SVC/1/ROOT/binovaliclient" Return="check"/>
<InstallExecuteSequence>
<Custom Action="MakeWepApp20" After="InstallFinalize">
FRAMEWORKDIR AND NOT Installed
</Custom>
</InstallExecuteSequence>
<Property Id="WIXUI_INSTALLDIR" Value="INSTALLDIR" />
<!--<Property Id="INSTALLDIR" Value="FRAMEWORKROOT" />-->
<Property Id="TARGETVDIR" Value="binovaliclient" />
<Property Id="PREVIOUSVERSIONSINSTALLED" Secure="yes" />
<Property Id="JSHARPINSTALLED">
<RegistrySearch Id="HASJSHARP" Root="HKLM"
Key="SOFTWARE\Microsoft\Visual JSharp Setup\Redist\v$(var.NetVersion)"
Type="raw" Name="Install" Win64='yes' />
</Property>
<PropertyRef Id="NETFRAMEWORK20" />
<Upgrade Id="3C6E5A3D-4127-4F3F-9BE7-C1F2939C959C">
<UpgradeVersion Minimum="1.3.0"
Maximum="$(var.ProductVersion)"
Property="PREVIOUSVERSIONSINSTALLED" IncludeMinimum="yes"
IncludeMaximum="no" />
</Upgrade>
<!--Gestion des icones orange et de la bannière Ovali-->
<UIRef Id="GenericToolUI" />
<Binary Id="BannerIcon" SourceFile="..\..\..\Installer\bannerOvali.bmp"
/>
<Binary Id="ErrorIcon" SourceFile="..\..\..\Installer\orange.ico" />
<InstallExecuteSequence>
<RemoveExistingProducts After="InstallInitialize" />
</InstallExecuteSequence>
</Product>
</Wix>
Do you have any idea or anything that could help me ?
Cordialement,
Julien BRASSELET
Ingénieur d'étude
Sopra group.
Centre Espace Performance - Batiment S
35769 St Grégoire
Phone : +33 (0)2 23 25 40 25
[email protected]<mailto:[email protected]> -
www.sopragroup.com<http://www.sopragroup.com/>
This message may contain confidential and proprietary material for the sole use
of the intended recipient. Any review or distribution by others is strictly
prohibited. If you are not the intended recipient, please contact the sender
and delete all copies.
P Before printing, think about the environment.
------------------------------------------------------------------------------
Minimize network downtime and maximize team effectiveness.
Reduce network management and security costs.Learn how to hire
the most talented Cisco Certified professionals. Visit the
Employer Resources Portal
http://www.cisco.com/web/learning/employer_resources/index.html
_______________________________________________
WiX-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/wix-users