[wix-users] Defining Directories{
Steven Packer
stevenp at fps-gold.com
Fri Oct 23 06:41:40 PDT 2015
I found the problem. I had an error in how I defined the bindpath using the IDE of VS. Once I corrected that then what I was trying to do with the WixVariable worked just fine.
Steven
-----Original Message-----
From: wix-users [mailto:wix-users-bounces at lists.wixtoolset.org] On Behalf Of Phill Hogland
Sent: Friday, October 23, 2015 7:33 AM
To: WiX Toolset Users Mailing List
Subject: Re: [wix-users] Defining Directories{
>> Are there some restrictions for the use of bindpath
http://wixtoolset.org/documentation/manual/v3/overview/light.html
Both a WixVariable and a bindpath are resolved by the binder phase of the linker, so I don't know why it is useful to put a bindpath in a WixVariable if it was supported. And since both sides of the statement cannot be resolved until the binder stage it actually makes since that it would not work.
>> I get the cannot find file error with this.
Generally, the output in a 'normal' build log has enough information to see the exact paths that were passed to light.exe with the -b (bindpath) flag, and the error message related to a File/@Source path that could not be resolved. Concatenating those paths should match your actual source path to the file. If you need more info then enable 'diagnostic' level of output logging in VS Tool\Options\Projects and Solutions\Build and Run\MSBuild project build output verbosity.
-----Original Message-----
From: wix-users [mailto:wix-users-bounces at lists.wixtoolset.org] On Behalf Of Steven Packer
Sent: Thursday, October 22, 2015 4:27 PM
To: 'WiX Toolset Users Mailing List' <wix-users at lists.wixtoolset.org>
Subject: Re: [wix-users] Defining Directories{
Thank You, this was very helpful. I have added the bindpath and it works nicely.
I tried to use the bindpath in this way for a WixVariable: <WixVariable Id="WixUIDialogBmp" Value="!(bindpath.CommonInstallFiles)\Install Images\FPSGOLDWelcomeOld.bmp" />
I get the cannot find file error with this.
Are there some restrictions for the use of bindpath
Steven
-----Original Message-----
From: wix-users [mailto:wix-users-bounces at lists.wixtoolset.org] On Behalf Of Phill Hogland
Sent: Thursday, October 22, 2015 1:41 PM
To: WiX Toolset Users Mailing List
Subject: Re: [wix-users] Defining Directories{
I concur with Edwin's (and John's) comments. I have used several of the approaches detailed in the specifying_source_files link. The approach that I eventually settled on was to use named bindpaths.
Given a 'Source' tree something like:
\\myserver\dir1\dir2\App1\
My File element looks something like:
<Component Id="log4net.dll" Guid="*" Directory="myAppDir" >
<File Id="log4net.dll" KeyPath="yes" Source="!(bindpath.App1)\log4net.dll" />
</Component>
And in the .wixproj file I define the path to the source file for the named bindpath.App1 location:
In a property group that I added after the '$(Configuration)|$(Platform)' == .... Property Groups so that it is common to all configurations.
<PropertyGroup>
....
<LinkerAdditionalOptions>
$(LinkerAdditionalOptions)
-nologo
-b App1="\\myserver\dir1\dir2\App1\\"
</LinkerAdditionalOptions>
</PropertyGroup>
The above entries can also be edited in the VS IDE by right-clicking on the Project, select Properties, select ToolSettings
As Edwin indicated the Directory tree, where you defined myAppDir, describes the folders on the user's target system.
-----Original Message-----
From: wix-users [mailto:wix-users-bounces at lists.wixtoolset.org] On Behalf Of Edwin Castro
Sent: Thursday, October 22, 2015 2:21 PM
To: WiX Toolset Users Mailing List <wix-users at lists.wixtoolset.org>
Subject: Re: [wix-users] Defining Directories{
The directory tree you are defining rooted at TARGETDIR represents the directories on the target system where your software will get installed. It does *not* represent the source system where you are building the installer.
Read How To: Specify source files at
http://wixtoolset.org/documentation/manual/v3/howtos/general/specifying_source_files.html
--
Edwin G. Castro
On 10/22/15, Steven Packer <stevenp at fps-gold.com> wrote:
> Thank you for your reply. However, after removing the HomeDrive
> Directory element I still get the same cannot find file error. In
> further study I find that TARGETDIR should resolve to C:\ since I only
> have one drive on my computer.
> <Fragment>
> <Directory Id="TARGETDIR" Name="SourceDir">
> <Directory Id="TFS" Name="TFS">
> <Directory Id="CIM" Name="CIM">
> <Directory Id="Trunk" Name="trunk">
> <Directory Id="CIMSourceDir" Name="bin">
> <Directory Id="CIMPlugins" Name="Plugins" />
> <Directory Id="CIMHelpFiles" Name="Help" />
> </Directory>
> </Directory>
> </Directory>
> </Directory>
> <Directory Id="ProgramFilesFolder">
> <Directory Id="FPSGOLD" Name="FPSGOLD">
> <Directory Id="INSTALLDIR" Name="CIM">
> <Directory Id="Plugins" Name="Plugins" />
> <Directory Id="Help" Name="Help" />
> </Directory>
> </Directory>
> </Directory>
> </Directory>
> </Fragment>
>
> With this understanding I would expect that CIMSourceDir would resolve to:
> C:\TFS\CIM\trunk\bin
> CIMPLUGINS would resolve to: C:\TFS\CIM\trunk\bin\Plugins And so on..
> It would seem that I am still lacking in understanding.
>
> Steven
>
> -----Original Message-----
> From: wix-users [mailto:wix-users-bounces at lists.wixtoolset.org] On
> Behalf Of John Cooper
> Sent: Thursday, October 22, 2015 11:30 AM
> To: WiX Toolset Users Mailing List
> Subject: Re: [wix-users] Defining Directories{
>
> Remove the "HomeDrive". TARGETDIR effectively performs that function.
>
> --
> John Merryweather Cooper
> Senior Software Engineer | Integration Development Group | Enterprise
> Notification Service Jack Henry & Associates, Inc.® | Lenexa, KS
> 66214 |
> Ext: 431050 |JoCooper at jackhenry.com
>
>
>
> -----Original Message-----
> From: wix-users [mailto:wix-users-bounces at lists.wixtoolset.org] On
> Behalf Of Steven Packer
> Sent: Thursday, October 22, 2015 12:29 PM
> To: wix-users at lists.wixtoolset.org
> Subject: [wix-users] Defining Directories{
>
> The e-mail below is from an external source. Please do not open
> attachments or click links from an unknown or suspicious origin.
>
> I am brand new to WiX. I am trying to setup a path to where my
> payload files are but can't seem to figure it out.
>
> I have created a Visual Studio WiX msi Project. This is what I am
> currently trying to do with the Directories.
>
>
>
> <Fragment>
>
> <Directory Id="TARGETDIR" Name="SourceDir">
>
> <Directory Id="HomeDrive">
>
> <Directory Id="TFS" Name="TFS">
>
> <Directory Id="CIM" Name="CIM">
>
> <Directory Id="Trunk" Name="trunk">
>
> <Directory Id="CIMSourceDir" Name="bin">
>
> <Directory Id="CIMPlugins" Name="CIMPlugins" />
>
> <Directory Id="CIMHelpFiles" Name="CIMHelpFiles" />
>
> </Directory>
>
> </Directory>
>
> </Directory>
>
> </Directory>
>
> </Directory>
>
> <Directory Id="ProgramFilesFolder">
>
> <Directory Id="FPSGOLD" Name="FPSGOLD">
>
> <Directory Id="INSTALLDIR" Name="CIM">
>
> <Directory Id="Plugins" Name="Plugins" />
>
> <Directory Id="Help" Name="Help" />
>
> </Directory>
>
> </Directory>
>
> </Directory>
>
> </Directory>
>
> </Fragment>
>
>
>
> In the File element I am putting Source"CIMSourceDir\MyFile.dll" or
> "CIMPlugins\plugin.dll" or "CIMHelpFiles\help.chm"
>
>
>
> I get the error The system cannot find the file 'CIMSourceDir\Myfile.dll'
>
> Same message for all of my files.
>
>
>
> The files are currently located on my machine at C:\TFS\CIM\trunk\bin
> and in Plugins and Help Directories below that. They will not always
> be there.
>
> The goal will be eventually to have this run in a build server to
> create the msi for a product that has hundreds of dlls and help files.
>
>
>
> I have created a simple msi already for a small internal program I wrote.
> The WiX project is part of the Visual Studio solution and builds very
> nicely with that small product.
>
> Now I am going much bigger and far more complex.
>
>
>
> Thanks,
>
> Steven
>
>
>
>
> ____________________________________________________________________
> WiX Toolset Users Mailing List provided by FireGiant
> http://www.firegiant.com/
>
> NOTICE: This electronic mail message and any files transmitted with it
> are intended exclusively for the individual or entity to which it is addressed.
> The message, together with any attachment, may contain confidential
> and/or privileged information.
> Any unauthorized review, use, printing, saving, copying, disclosure or
> distribution is strictly prohibited. If you have received this message
> in error, please immediately advise the sender by reply email and
> delete all copies.
>
>
> ____________________________________________________________________
> WiX Toolset Users Mailing List provided by FireGiant
> http://www.firegiant.com/
>
>
>
> ____________________________________________________________________
> WiX Toolset Users Mailing List provided by FireGiant
> http://www.firegiant.com/
>
--
Edwin G. Castro
____________________________________________________________________
WiX Toolset Users Mailing List provided by FireGiant http://www.firegiant.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/
____________________________________________________________________
WiX Toolset Users Mailing List provided by FireGiant http://www.firegiant.com/
More information about the wix-users
mailing list