简体   繁体   中英

Error while trying to build WiX installer

I am trying to build a WiX installer for my project, but everytime I build it I get these 4 errors:

Unresolved reference to symbol 'WixComponentGroup:ServerGUIPlugin.Sources' in section 'Product:{3BEDB48C-1347-4875-AA2C-920435B662E3}'. C:\Users\...\WixInstaller\Product.wxs 33
Unresolved reference to symbol 'WixComponentGroup:ServerGUIPlugin.Binaries' in section 'Product:{3BEDB48C-1347-4875-AA2C-920435B662E3}'.    C:\Users\...\WixInstaller\Product.wxs 34
Unresolved reference to symbol 'WixComponentGroup:AttachToGUI.Binaries' in section 'Product:{3BEDB48C-1347-4875-AA2C-920435B662E3}'.    C:\Users\...\WixInstaller\Product.wxs 37
Unresolved reference to symbol 'WixComponentGroup:ServerGUI.Binaries' in section 'Product:{3BEDB48C-1347-4875-AA2C-920435B662E3}'.  C:\Users\...\WixInstaller\Product.wxs 38

They are referencing to this piece of code in Product.wxs:

<Feature Id="ProductFeature" Title="WixInstaller" Level="1"> 
  <ComponentGroupRef Id="ServerGUIPlugin.Sources" />    <!--This line-->
  <ComponentGroupRef Id="ServerGUIPlugin.Binaries" />   <!--This line-->
  <ComponentGroupRef Id="RegistryGroup" />
  <ComponentRef Id="comp_4ABDC32C_56A9_4E3D_9640_14D1E430A1CD" />
  <ComponentGroupRef Id="AttachToGUI.Binaries" />       <!--This line-->
  <ComponentGroupRef Id="ServerGUI.Binaries" />         <!--This line-->
  <ComponentRef Id="comp_22A86C14_76CC_472B_9016_90FD42925402" />
</Feature>

I have searched for a solution on the internet but I just started using WiX Toolset and most of the time I don't know what they are talking about. Can anyone tell me why this is causing errors or what I should do to fix it?

Update Our problem was solved! Here is how we did it:

    <Fragment>
        <Directory Id="TARGETDIR" Name="SourceDir">
          <Component Id="comp_22A86C14_76CC_472B_9016_90FD42925402" Guid="..." Permanent="no" SharedDllRefCount="no" Transitive="no">
            <File Id="..." DiskId="1" Hidden="no" ReadOnly="no" TrueType="no" System="no" Vital="yes" Name="GMap.NET.Core.dll" Source="..." KeyPath="yes" />
            <File Id=".." DiskId="1" Hidden="no" ReadOnly="no" TrueType="no" System="no" Vital="yes" Name="GMap.NET.WindowsForms.dll" Source="..." />
            <File Id="..." DiskId="1" Hidden="no" ReadOnly="no" TrueType="no" System="no" Vital="yes" Name="GUIComponents.dll" Source="..." />
            <File Id="..." DiskId="1" Hidden="no" ReadOnly="no" TrueType="no" System="no" Vital="yes" Name="ServerGUIPlugin.dll" Source="..." />
          </Component>
          <Directory Id="..." Name="Plugin Source">
            <Directory Id="ServerGUIPlugin.Sources" />
            <Directory Id="ServerGUIPlugin.Binaries" />
          </Directory>
          <Directory Id="AttachToGUI.Binaries" />
          <Directory Id="ServerGUI.Binaries" />
          <Component Id="comp_4ABDC32C_56A9_4E3D_9640_14D1E430A1CD" Guid="..." Permanent="no" SharedDllRefCount="no" Transitive="no">
            <File Id="..." DiskId="1" Hidden="no" ReadOnly="no" TrueType="no" System="no" Vital="yes" Name="Attach.ico" Source="..." KeyPath="yes" />
        </Component>
        </Directory>
        <DirectoryRef Id="ServerGUI.Binaries">
          <Component Id="ServerGUI.exe" Guid="...">
            <File Id="ServerGUI.exe" Source="..." KeyPath="yes" Checksum="yes" />
          </Component>
        </DirectoryRef>
        <DirectoryRef Id="AttachToGUI.Binaries">
          <Component Id="AttachToGUI.exe" Guid="...">
            <File Id="AttachToGUI.exe" Source="..." KeyPath="yes" Checksum="yes" />
          </Component>
        </DirectoryRef>
        <DirectoryRef Id="ServerGUIPlugin.Binaries">
          <Component Id="ServerGUIPlugin.dll" Guid="...">
            <File Id="ServerGUIPlugin.dll" Source="..." KeyPath="yes" Checksum="yes" />
          </Component>
        </DirectoryRef>
        <DirectoryRef Id="ServerGUIPlugin.Sources">
          <Component Id="PluginBase.cs" Guid="...">
            <File Id="PluginBase.cs" Source="..." KeyPath="yes" Checksum="yes" />
          </Component>
          <Component Id="SGPluginAttribute.cs" Guid="...">
            <File Id="SGPluginAttribute.cs" Source="..." KeyPath="yes" Checksum="yes" />
          </Component>
        </DirectoryRef>
      </Fragment>
      <Fragment>
        <ComponentGroup Id="ServerGUI.Binaries">
          <ComponentRef Id="ServerGUI.exe" />
        </ComponentGroup>
        <ComponentGroup Id="AttachToGUI.Binaries">
          <ComponentRef Id="AttachToGUI.exe" />
        </ComponentGroup>
        <ComponentGroup Id="ServerGUIPlugin.Binaries">
          <ComponentRef Id="ServerGUIPlugin.dll" />
        </ComponentGroup>
        <ComponentGroup Id="ServerGUIPlugin.Sources">
          <ComponentRef Id="PluginBase.cs" />
          <ComponentRef Id="SGPluginAttribute.cs" />
        </ComponentGroup>
      </Fragment>

That's a lot of code but since I coulnd't find it anywhere I figured I may as well leave it here

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM