【问题标题】:How to change $(var.Platform) from x86 to Win32 in Wix如何在 Wix 中将 $(var.Platform) 从 x86 更改为 Win32
【发布时间】:2015-06-16 16:22:32
【问题描述】:

我有一个 Visual C++ 2013 解决方案,包括许多 C++ 项目和一个 WIX 安装程序项目。 在 x64 平台上,一切正常。 但是在x86平台上,C++项目的$(OutDirectory)$(Platform)$(Configuration)是...Win32...,但是WIX的$(OutDirectory)$(Platform)$(Configuration)是...x86。 .. 我能做什么?

【问题讨论】:

    标签: c++ wix platform


    【解决方案1】:

    您应该将所有项目作为参考添加到您的 WiX 项目中。假设您的一个 C++ 项目名为“MyHelperProject”。您可以像这样访问该项目的输出二进制文件:

    <Component Guid="{723E4174-C9D2-4385-844E-C7D035B0C8FB}" Directory="INSTALL_ROOT">
        <File Source="$(var.MyHelperProject.TargetPath)" KeyPath="yes"/>   
    </Component>
    

    或者,如果您想从该构建中获取其他文件:

    <Component Guid="{A0D64469-A90C-4DF3-A54B-B386AC49E6E7}" Directory="INSTALL_ROOT">
        <File Source="$(var.MyHelperProject.TargetDir)required_file.txt" KeyPath="yes"/>
    </Component>
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多