Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge modules fail to build when intermediate path contains spaces #7294

Closed
iwarp opened this issue Mar 22, 2023 · 3 comments · Fixed by wixtoolset/wix#376
Closed

Merge modules fail to build when intermediate path contains spaces #7294

iwarp opened this issue Mar 22, 2023 · 3 comments · Fixed by wixtoolset/wix#376
Assignees
Labels
Milestone

Comments

@iwarp
Copy link

iwarp commented Mar 22, 2023

Triage

Issues are triaged at online meetings, generally held alternate Thursdays at 9:30 a.m. Pacific time (UTC-7/UTC-8). Meeting requests are sent to the wix-devs and wix-users mailing lists, as well as in Discussions.

Discussions and support

Note that discussions are best held on the mailing lists not in issues. Please do not open issues requesting support or debugging help; first start a thread on the wix-users mailing list and open an issue if the discussion suggests a bug in the WiX Toolset or that a feature request is appropriate. You can also try out the beta Discussions feature.

Instructions

Read the sections above. Delete the Triage, Discussions and support, and Instructions sections and fill out the rest.

Bugs

If this issue is a bug:

  • Which version of WiX are you building with?

4.0.0-rc.4+dea44a7d

  • Which version of Visual Studio are you building with (if any)?

VS 2022 Community 17.5.2

  • Which version of the WiX Toolset Visual Studio Extension are you building with (if any)?

0.9.5

  • Which version of .NET are you building with?

4.8

  • If the problem occurs when installing your packages built with WiX, what is the version of Windows the package is running on?

Windows 11 22621.1413

  • Describe the problem and the steps to reproduce it.

(Be as specific as you can and err on the side of providing too much information, including code, error messages, command lines you used to invoke the build, and so forth.)

  • Describe the behavior you expected and how it differed from the actual behavior.

I have been upgrading my Wix3 project to Wix4, I have 3 Merge Modules for VC++ Redistributables. Building from msbuild in my build pipeline and via VS2022 Right Click Build. I end up with the following error

wix.exe : error WIX0017: Failed to extract cab 'C:\Subversion\Trunk Clean\SetupMSI\obj\x86\Debug\VCRedist2017.cab' from merge module 'Redists\Microsoft_VC140_CRT_x86.msm' to directory 'C:\Subversion\Trunk Clean\SetupMSI\obj\x86\Debug\VCRedist2017'. This is most likely due to a lack of available disk space on the destination drive

Running "wix build test.wxs" successfully builds the MSI, I've tracked this down to the -intermediatefolder flag, appending this to the build caused this to fail. "wix build mergetest.wxs -intermediatefolder obj\x86\Debug"

Example: test.wxs

<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs">
	<Package Name="Test" Version="1.2.3.4" UpgradeCode="FA6768C3-9010-4B20-B03F-F3FC751F3A26" Manufacturer="Test">
		<Media Id="1" Cabinet="data.cab" EmbedCab="yes" />
		<Feature Id="VCRedist2017Feature" Title="Visual C++ 14.0 (2015, 2017, 2019) Runtime" Level="1" AllowAdvertise="no" Description="Supporting Libraries for Helix.">
			<MergeRef Id="VCRedist2017" />
		</Feature>
		<DirectoryRef Id="TARGETDIR">
			<Merge Id="VCRedist2017" SourceFile="Redists\Microsoft_VC140_CRT_x86.msm" DiskId="1" Language="0" />
		</DirectoryRef>
	</Package>
</Wix>

The error message here is hiding the underlying error, adding some additional debugging into src\wix\WixToolset.Core.WindowsInstaller\Bind\ExtractMergeModuleFilesCommand.cs line 216.

I get the following underlying error:
wixnative.exe failed with error code: -2147467259 - The filename, directory name, or volume label syntax is incorrect. Output:
api_ms_win_core_console_l1_1_0.dll.41084701_5F61_3497_AC5D_D0A6D4A85536

I'm unable to trace this in the code base well enough to find the source of this error.

I can upload the msm if required.

@iwarp iwarp added the triage label Mar 22, 2023
@iwarp iwarp changed the title Merge Modules Fails to Build from Heatwave & msbuild Merge modules fails to build from heatwave & msbuild Mar 22, 2023
@barnson
Copy link
Member

barnson commented Mar 22, 2023

Doesn't repro on Win10. Can you push a repo with the necessary files and steps to repro?

@iwarp
Copy link
Author

iwarp commented Mar 22, 2023

Hi @barnson, worked out how to repo it, the folder path c:\git\wix4-msm-bug\ works

But if you introduce a space into the name at any level of the parent folder, eg c:\git\wix4 msm bug\ if fails.

@iwarp
Copy link
Author

iwarp commented Mar 22, 2023

Repo for Repro - https://github.com/iwarp/wix4-msm-bug

@robmen robmen self-assigned this Mar 23, 2023
@robmen robmen added the binder label Mar 23, 2023
@robmen robmen added this to the v4.0 milestone Mar 23, 2023
@barnson barnson removed the triage label Mar 23, 2023
@robmen robmen changed the title Merge modules fails to build from heatwave & msbuild Merge modules fail to build when intermediate path contains spaces Mar 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants