Hi, 

 

I use Votive (WiX 3.5) with VS 2008. I have added two projects in the
solution. One is a WiX project and another one is a library project
which implements a CustomAction. WiX project references the library:

 

<ItemGroup>

    <ProjectReference
Include="..\InstallDataBase\InstallDataBase.csproj">

      <Name>InstallDataBase</Name>

      <Project>{e67df855-60e0-4abf-abf7-46ecea4f64a1}</Project>

      <Private>True</Private>

      <DoNotHarvest>True</DoNotHarvest>

 
<RefProjectOutputGroups>Binaries;Content;Satellites</RefProjectOutputGro
ups>

      <RefTargetDir>INSTALLLOCATION</RefTargetDir>

    </ProjectReference>

  </ItemGroup>

 

And I use the following:

<Binary Id="DBScriptAction"
SourceFile="$(var.InstallDataBase.TargetDir)$(var.InstallDataBase.Target
Name).CA.dll" />

to call the custom action from the WiX project. It works ok when I build
the WiX project in Visual Studio.

 

But it doesn't work when I build it using MSBuild task. In my build
definition I use the following:

<MSBuild Projects="@(WixProject)" Condition="'$(CreateSetup)'=='true'"
Properties
="MsiInstallVersion=$(Major).$(Minor).$(Build).$(Revision);AutoBuild=Tru
e"/>

 

I'm getting this error when using MSBuild:

 

Product.wxs(361): error CNDL0150: Undefined preprocessor variable
'$(var.InstallDataBase.TargetDir)'.

 

I checked the build outputs from both VS and MSBuild and the difference
is that when building in MSBuild the candle.exe doesn't have the
properties for the library project (for instance
-dLibraryProjectName.ProjectDir, etc.).

 

It looks to me that when building wixproj from MSBuild task candle do
not provide the properties for the referenced project.

 

 

Thanks,

--

Ruslan Albu

 

------------------------------------------------------------------------------
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to