[wix-users] Some questions

William Fisher wfisher at summa.com
Fri Jul 14 12:43:28 PDT 2017


More information, if anyone has any advice:

I tried using the Bootstrapper.config found here
http://wixtoolset.org/documentation/manual/v3/howtos/redistributables_and_install_checks/install_dotnet.html
and
changed the name of my boostrapper assembly name, and I got this on my
Windows 10 system:

[2788:2780][2017-07-14T15:33:23]e000: Error 0x80131902: Failed to create
the managed bootstrapper application.
[2788:2780][2017-07-14T15:33:23]e000: Error 0x80131902: Failed to create UX.
[2788:2780][2017-07-14T15:33:23]e000: Error 0x80131902: Failed to load UX.
[2788:2780][2017-07-14T15:33:23]e000: Error 0x80131902: Failed while
running

Googling that led me to ".NET isn't installed"
https://ricardodsanchez.com/error-0x80131902-failed-to-create-the-managed-bootstrapper-application/

So it looks like it's trying to use .NET 3.5 exclusively.  I thought this
part:

  <startup useLegacyV2RuntimeActivationPolicy="true">
    <supportedRuntime version="v2.0.50727" />
    <supportedRuntime version="v4.0" />
  </startup>

made it compatible, so I'm a bit confused.

On Fri, Jul 14, 2017 at 12:32 PM William Fisher <wfisher at summa.com> wrote:

> Yeah, if I use MY package instead of the NetFx package, I can install .NET
> quietly.  The problem is, the Bootstrapper says "I need .NET!" before it
> even gets to my package (or the redist).
>
> On Fri, Jul 14, 2017 at 12:27 PM Habib Salim <habib at hsalim.com> wrote:
>
>> I am developing a reporting application and my needs are quite similar to
>> yours.
>>
>> I too went down the same path and temporarily abandoned it.  for now, I am
>> handling pre-requisites manually.
>> You use the netFX extension to determine if the .net version of the target
>> machine.  if it does not, you can choose to install it using your
>> bootstrapper.
>> I'm quite sure you can suppress the .netFX UI by doing a silent install of
>> the framework.
>>
>> I too wanted to install SQL Express 2014 - but only for those who did not
>> want to install my application and related databases on an existing SQL
>> instance.
>> (In my case the database stores report metadata but the application is
>> used to query various data sources, with SQL data sources being the usual
>> case.)
>>
>> I decided against bootstrapping SQL because
>> a. the SQL installer was huge, causing my installer to be huge - the
>> installer for my application is some 40 MB - (I don't understand why it is
>> even that big. Whatever.)
>> With SQL it went over 300 MB, and
>> b. installing SQL and configuring all those options is not an easy task or
>> one that I want to take on.  (Thanks to Chris Painter for dissuading from
>> this path)
>>
>> I still need to create that database and script all the objects, initial
>> data etc.
>>
>> I need to get back to building a complete bootstrapper application.
>> When I do, I'll probably use a custom BA application like JetBA, mostly
>> because
>> a. it simplifies a lot
>> b. Nir bar, the author of JetBA is the Wix guru
>> c. I know I can count on Nir to help with any issues because he is
>> constantly contributing here.
>>
>> I would also look at Chris Painter's IsWix, who is also a frequent
>> contributor here.
>>
>>
>>
>>
>>
>>
>>
>> -----Original Message-----
>> From: wix-users [mailto:wix-users-bounces at lists.wixtoolset.org] On Behalf
>> Of William Fisher
>> Sent: Friday, July 14, 2017 11:00 AM
>> To: WiX Toolset Users Mailing List <wix-users at lists.wixtoolset.org>
>> Subject: Re: [wix-users] Some questions
>>
>> I appreciate any responses.  Will using the NetFx Extension force me to
>> use the .NET installer UI?  That doesn't match our requirements.  Here are
>> the problems I'm currently experiencing:
>>
>> Context:  I have to install .NET 4.6.2, SQL Server Express 2014 (may
>> change, not particularly relevant), the client product application, and
>> then run a DB script.  The target systems are Windows 7 SP 1 (minimum
>> possible for .NET 4.6.2) through Windows 10.  32-bit and 64-bit (I have
>> solved any issues with this, unless that causes any of the below issues).
>> We cannot assume the end-user system is connected to the internet.  My
>> default assumption is that they have NOT done Windows Update (as they're
>> not connected to the internet), so Win 7 SP 1 with no updates is my
>> possible minimum.
>>
>> 1> Windows 7 has .NET 3.5, whereas Windows 10 has 4.x. The installer
>> 1> works
>> on Windows 10 (caveat the icon and some UI stuff I have to finish), but
>> Windows 7, it does not.  I couldn't figure out how to use NetFx extension
>> NetFx462Redist version with the included redistributable.  In addition, I
>> would like the UI for .NET installer to be my UI, not the stock .NET
>> installer UI.
>>
>> 2>  Windows 7 does not report (or WIX doesn't log, see item 3)
>> 2> WindowsNT,
>> WindowsBuild, or ServicePackValue value in Windows 7 (it works in Windows
>> 10):
>>                             var versionNT =
>> BootstrapperApplication.Engine.NumericVariables.Contains("VersionNT")
>>                             ?
>> BootstrapperApplication.Engine.NumericVariables["VersionNT"]
>>                             : 1000; // Arbitrary value > 601
>>
>> 2.5>
>> https://blogs.msdn.microsoft.com/vsnetsetup/2016/03/28/a-certificate-chain
>> -could-not-be-built-to-a-trusted-root-authority-2/
>> <https://blogs.msdn.microsoft.com/vsnetsetup/2016/03/28/a-certificate-chain-could-not-be-built-to-a-trusted-root-authority-2/>
>> -
>> I need to detect if it's Windows 7 SP1 to install this certificate for
>> systems that are not connected to the internet (which is a possibility at
>> end-user locations).
>>
>> 3>  When logging data using
>> BootstrapperApplication.Engine.Log(LogLevel.Verbose, "LOG TEXT GOES
>> HERE"); I see results in Windows 10, but nothing in Windows 7.
>>
>> (Example logging from #2 and #3 combined:
>> [3394:32BC][2017-07-13T16:43:28]i000: ***** Windows Version:
>> 2814749767106560.10000.10 // The first number is what WindowsNT returns
>> for Win10.  The 10000.10 are arbitrary values I assigned if the variable
>> doesn't exist.
>> [3394:32BC][2017-07-13T16:43:28]i000: ***** Is 64Bit OS: True
>> [3394:32BC][2017-07-13T16:43:28]i000: ***** Is after reboot: False
>> )
>>
>> 4>  The icon for the built installer is the stock installer icon,
>> 4> instead
>> of the icon I want it to be (which is     <Icon Id="shield.ico"
>> SourceFile="Resources\client_logo.ico"/> )
>>
>> If anyone can get me going with #1 and #2, I'm less concerned about #3,
>> and
>> #4 is definitely a "nice-to-have" to start.
>>
>> NetFx DLL is referenced in the project that contains my wxs file Relative
>> to the project file (i.e. not in bin/Debug, just in the root of the
>> project), I have redist\NDP462-KB3151800-x86-x64-AllOS-ENU.exe
>> All the other packages successfully install when running on Windows 10.
>>
>> BootstrapperCore.config:
>>
>> <?xml version="1.0" encoding="utf-8" ?>
>> <configuration>
>>   <configSections>
>>     <sectionGroup name="wix.bootstrapper"
>> type="Microsoft.Tools.WindowsInstallerXml.Bootstrapper.BootstrapperSection
>> Group,
>> BootstrapperCore">
>>       <section name="host"
>> type="Microsoft.Tools.WindowsInstallerXml.Bootstrapper.HostSection,
>> BootstrapperCore" />
>>     </sectionGroup>
>>   </configSections>
>>   <startup useLegacyV2RuntimeActivationPolicy="true">
>> <!-- I've tried adding version="v2.0.whatever the numbers for 3.5 are",
>> and version ="v3.5" -->
>>     <supportedRuntime version="v4.0" />
>>   </startup>
>>   <wix.bootstrapper>
>>     <host assemblyName="ApplicationBootstrapper">
>> <!-- I've tried adding version="v2.0.whatever the numbers for 3.5 are",
>> and version ="v3.5" -->
>>       <supportedFramework version="v4\Client" />
>>     </host>
>>   </wix.bootstrapper>
>> </configuration>
>>
>> Bundle.wxs:
>>
>> <?xml version="1.0" encoding="UTF-8"?>
>> <?include Includes/ApplicationVariables.wxi ?> <Wix
>> xmlns="http://schemas.microsoft.com/wix/2006/wi"
>>      xmlns:util="http://schemas.microsoft.com/wix/UtilExtension"
>>      xmlns:netfx="http://schemas.microsoft.com/wix/NetFxExtension">
>> <Bundle
>>     Name="$(var.ProductName)"
>>     Version="$(var.VersionNumber)"
>>     Manufacturer="$(var.ManufacturerName)"
>>     UpgradeCode="64857b79-4f2d-48ef-ae8a-08bab1d77294"
>>     Compressed="yes">
>>     <BootstrapperApplicationRef Id="ManagedBootstrapperApplicationHost">
>>       <PayloadGroupRef Id="InstallerPayload" />
>>     </BootstrapperApplicationRef>
>>  <util:User Id="SQLsa"
>>             Name="[sa]"
>>             Password="[Password1!]" />
>> <Chain>
>> <PackageGroupRef Id="CertificatePackage"/>
>>       <PackageGroupRef Id="NetFx462" After="CertificatePackage"/>
>>       <PackageGroupRef Id="SQLServerExpress2014_64Bit"/>  <PackageGroupRef
>> Id="SQLServerExpress2014_32Bit"/>
>>       <PackageGroupRef Id="Application64Bit"/>
>>       <PackageGroupRef Id="Application32Bit"/>
>>       <PackageGroupRef Id="Client.Application.Database.Installer"/>
>> </Chain>
>> </Bundle>
>>   <Fragment>
>>     <util:RegistrySearch
>>       Id="NETFRAMEWORK462"
>>       Variable="NETFRAMEWORK462"
>>       Root="HKLM"
>>       Key="SOFTWARE\Microsoft\NET Framework Setup\NDP\v4\Full"
>>       Value="Install"
>>       Result="value"/>
>>     <WixVariable Id="WixMbaPrereqPackageId" Value="NetFx462Redist" />
>>     <WixVariable Id="WixMbaPrereqLicenseUrl" Value="
>> https://msdn.microsoft.com/en-us/library/ms994405.aspx" Overridable="yes"
>> />
>>     <PackageGroup Id="NetFx462">
>>       <ExePackage Id="NetFx462"
>>                   Cache="no"
>>                   Compressed="yes"
>>                   PerMachine="yes"
>>                   Permanent="yes"
>>                   Vital="yes"
>>                   Name="NDP462-KB3151800-x86-x64-AllOS-ENU.exe"
>>
>> SourceFile="redist\NDP462-KB3151800-x86-x64-AllOS-ENU.exe"
>>                   DetectCondition="NETFRAMEWORK462"
>>                   InstallCommand="/q /norestart"/>
>>     </PackageGroup>
>>   </Fragment>
>>   <Fragment>
>>     <PayloadGroup Id="InstallerPayload">
>>       <!-- TODO: determine relative sources to prevent errors when moving
>> the solution -->
>>       <Payload SourceFile="C:\\Users\\310284944\\Documents\\Visual Studio
>> 2015\\Projects\\Client.Application.Setup\\ApplicationBootstrapper\\bin\\De
>> bug\\ApplicationBootstrapper.dll"/>
>>       <Payload SourceFile="C:\\Users\\310284944\\Documents\\Visual Studio
>> 2015\\Projects\\Client.Application.Setup\\ApplicationBootstrapper\\Bootstr
>> apperCore.config"/>
>>       <Payload SourceFile="C:\\Users\\310284944\\Documents\\Visual Studio
>> 2015\\Projects\\Client.Application.Setup\\ApplicationBootstrapper\\bin\\De
>> bug\\Microsoft.Deployment.WindowsInstaller.dll"/>
>>       <Payload SourceFile="C:\\Users\\310284944\\Documents\\Visual Studio
>> 2015\\Projects\\Client.Application.Setup\\Client.Application.Installer.Use
>> rInterface\\bin\\Debug\\Client.Application.Installer.UserInterface.exe"/>
>>       <Payload Name="redist\\NDP462-KB3151800-x86-x64-AllOS-ENU.exe"
>>                SourceFile="C:\\Users\\310284944\\documents\\visual studio
>> 2015\\Projects\\Client.Application.Setup\\Client.Application.Setup\\redist
>> \\NDP462-KB3151800-x86-x64-AllOS-ENU.exe"/>
>>     </PayloadGroup>
>>   </Fragment>
>>   <Fragment>
>>      <!-- This package is a fix for
>> https://blogs.msdn.microsoft.com/vsnetsetup/2016/03/28/a-certificate-chain
>> -could-not-be-built-to-a-trusted-root-authority-2/
>> <https://blogs.msdn.microsoft.com/vsnetsetup/2016/03/28/a-certificate-chain-could-not-be-built-to-a-trusted-root-authority-2/>
>> on
>> Windows 7 - assuming I can detect Windows 7, which isn't working -->
>>     <PackageGroup Id="CertificatePackage">
>>       <MsiPackage Id="CertificatePackage"
>>                   Name="Client.Application.Certificate.Installer"
>>                   Compressed="yes"
>>                   Visible="no"
>>                   SourceFile="C:\\Users\\310284944\\Documents\\Visual
>> Studio
>> 2015\\Projects\\Client.Application.Setup\\Client.Application.Certificate.I
>> nstaller\\bin\\Release\\Client.Application.Certificate.Installer.msi"/>
>>     </PackageGroup>
>>   </Fragment>
>>   <Fragment>
>>     <util:RegistrySearch
>>       Id='SearchForSQLServerExpress64'
>>       Variable="ISSQLSERVER64INSTALLED"
>>       Result="exists"
>>       Root="HKLM"
>>       Key="SOFTWARE\Microsoft\Microsoft SQL
>> Server\MSSQL12.$(var.InstanceName)"
>>       Win64="yes" />
>>     <PackageGroup Id="SQLServerExpress2014_64Bit">
>>       <ExePackage Compressed="yes"
>>                   PerMachine="yes"
>>                   Cache="yes"
>>                   Vital="yes"
>>                   Permanent="no"
>>                   InstallCommand='/ACTION=Install /Q
>> /IACCEPTSQLSERVERLICENSETERMS /FEATURES=SQLEngine
>> /INSTANCENAME=$(var.InstanceName)
>> /SQLSYSADMINACCOUNTS=BUILTIN\Administrators /SECURITYMODE=SQL
>> /SAPWD="Password1!" /SkipRules=RebootRequiredCheck'
>>                   UninstallCommand='/ACTION=Uninstall /Q
>> /FEATURES=SQLEngine /INSTANCENAME=$(var.InstanceName)'
>>                   SourceFile='redist\SQLEXPR_x64_ENU.exe'
>>                   Name="redist\SQLEXPR_x64_ENU.exe"
>>                   DetectCondition="Installed OR ISSQLSERVER64INSTALLED"
>>                   InstallCondition="VersionNT64">
>>         <ExitCode Behavior="forceReboot"/>
>>       </ExePackage>
>>     </PackageGroup>
>>   </Fragment>
>>   <Fragment>
>>     <util:RegistrySearch
>>       Id='SearchForSQLServerExpress32'
>>       Variable="ISSQLSERVER32INSTALLED"
>>       Result="exists"
>>       Root="HKLM"
>>       Key="SOFTWARE\Microsoft\Microsoft SQL
>> Server\MSSQL12.$(var.InstanceName)"
>>       Win64="no" />
>>     <PackageGroup Id="SQLServerExpress2014_32Bit">
>>       <ExePackage Compressed="yes"
>>                   PerMachine="yes"
>>                   Cache="yes"
>>                   Vital="yes"
>>                   Permanent="no"
>>                   InstallCommand='/ACTION=Install /Q
>> /IACCEPTSQLSERVERLICENSETERMS /FEATURES=SQLEngine
>> /INSTANCENAME=$(var.InstanceName)
>> /SQLSYSADMINACCOUNTS=BUILTIN\Administrators /SECURITYMODE=SQL
>> /SAPWD="Password1!" /SkipRules=RebootRequiredCheck'
>>                   UninstallCommand='/ACTION=Uninstall /Q
>> /FEATURES=SQLEngine /INSTANCENAME=$(var.InstanceName)'
>>                   SourceFile='redist\SQLEXPR_x86_ENU.exe'
>>                   Name="redist\SQLEXPR_x86_ENU.exe"
>>                   DetectCondition="Installed OR ISSQLSERVER32INSTALLED"
>>                   InstallCondition="NOT VersionNT64">
>>         <ExitCode Behavior="forceReboot"/>
>>       </ExePackage>
>>     </PackageGroup>
>>   </Fragment>
>>   <Fragment>
>>     <PackageGroup Id="Application64Bit">
>>       <MsiPackage
>>         Name="Client.Application.Installer64"
>>         Compressed="yes"
>>         SourceFile="C:\Users\310284944\Documents\Visual Studio
>> 2015\Projects\Client.Application.Setup\Client.Application.Installer64\bin\
>> Debug\en-US\Client.Application.Installer64.msi"
>>         InstallCondition="VersionNT64" />
>>     </PackageGroup>
>>   </Fragment>
>>   <Fragment>
>>     <PackageGroup Id="Application32Bit">
>>       <MsiPackage
>>         Name="Client.Application.Installer32"
>>         Compressed="yes"
>>         SourceFile="C:\Users\310284944\Documents\Visual Studio
>> 2015\Projects\Client.Application.Setup\Client.Application.Installer32\bin\
>> Debug\en-US\Client.Application.Installer32.msi"
>>         InstallCondition="NOT VersionNT64" />
>>     </PackageGroup>
>>   </Fragment>
>>   <Fragment>
>>     <!-- Placed here as this fragment is guaranteed to be included.  The
>> Icon and Property can
>>          be placed anywhere in the WIX project. -->
>>     <Icon Id="shield.ico" SourceFile="Resources\client_logo.ico"/>
>>     <Property Id="ARPPRODUCTICON" Value="shield.ico"/>
>>     <PackageGroup Id="Client.Application.Database.Installer">
>>       <MsiPackage
>>         Name="Client.Application.Database.Installer"
>>         Compressed="yes"
>>         SourceFile="C:\Users\310284944\Documents\Visual Studio
>> 2015\Projects\Client.Application.Setup\Client.Application.Database.Install
>> er\bin\Debug\en-us\Client.Application.Database.Installer.msi"/>
>>     </PackageGroup>
>>   </Fragment>
>> </Wix>
>>
>> On Thu, Jul 13, 2017 at 6:33 PM Joel Budreau <joel.budreau at gmail.com>
>> wrote:
>>
>> > I think the recommendation is to use the NetFxExtension. Maybe you
>> > could get better help if you post the issues that you're running into
>> > with that extension?
>> >
>> > On Thu, Jul 13, 2017 at 2:06 PM, William Fisher <wfisher at summa.com>
>> wrote:
>> >
>> > > I'm writing a custom bootstrapper application, and I'm having a few
>> > > issues.  Hopefully someone can help with them:
>> > >
>> > > 1>
>> > > https://stackoverflow.com/questions/45089379/wix-
>> > > installer-net-3-5-and-net-4-x
>> > >
>> > > 2>  On Windows 10, the logging statements I included to find out
>> > > 2> some
>> > data
>> > > log correctly.  On Windows 7, they do not.  Is this a known issue?
>> > >
>> > > Thanks for any input.
>> > > --
>> > > Bill Fisher   |  Technical Consultant
>> > > [ *m* ] 412.427.9804 <(412)%20427-9804> <(412)%20427-9804>
>> wfisher at summa.com
>> > > [image: [ l ]] billfishersumma   <
>> > https://linkedin.com/in/billfishersumma>
>> > > 611 William Penn Place
>> > > Pittsburgh, PA 15219
>> > > summa.com <http://www.summa.com/> [image: Summa]
>> > > <http://www.summa.com/>
>> > >
>> > > ____________________________________________________________________
>> > > WiX Toolset Users Mailing List provided by FireGiant
>> > > http://www.firegiant.com/
>> > >
>> >
>> > ____________________________________________________________________
>> > WiX Toolset Users Mailing List provided by FireGiant
>> > http://www.firegiant.com/
>> >
>> --
>> Bill Fisher   |  Technical Consultant
>> [ *m* ] 412.427.9804 <(412)%20427-9804>
>> wfisher at summa.com
>> [image: [ l ]] billfishersumma   <https://linkedin.com/in/billfishersumma
>> >
>> 611 William Penn Place
>> Pittsburgh, PA 15219
>> summa.com <http://www.summa.com/> [image: Summa] <http://www.summa.com/>
>>
>> ____________________________________________________________________
>> WiX Toolset Users Mailing List provided by FireGiant
>> http://www.firegiant.com/
>>
>> ____________________________________________________________________
>> WiX Toolset Users Mailing List provided by FireGiant
>> http://www.firegiant.com/
>>
> --
> Bill Fisher   |  Technical Consultant
> [ *m* ] 412.427.9804 <(412)%20427-9804>
> wfisher at summa.com
> [image: [ l ]] billfishersumma   <https://linkedin.com/in/billfishersumma>
> 611 William Penn Place
> Pittsburgh, PA 15219
> summa.com <http://www.summa.com/> [image: Summa] <http://www.summa.com/>
>
-- 
Bill Fisher   |  Technical Consultant
[ *m* ] 412.427.9804
wfisher at summa.com
[image: [ l ]] billfishersumma   <https://linkedin.com/in/billfishersumma>
611 William Penn Place
Pittsburgh, PA 15219
summa.com <http://www.summa.com/> [image: Summa] <http://www.summa.com/>


More information about the wix-users mailing list