Symptom
With [toolchain] windows = "msvc@system", a package that has a host-module
build-dependency fails while compiling the build program:
error: host module 'huxerui.rules' compile failed (exit 2):
c1xx: fatal error C1083: Cannot open source file:
'huxerui.rules.sources=D:\a\HuxerUI\HuxerUI\target\.build-mcpp\huxerui.rules.sources.ifc':
No such file or directory
cl.exe is reading huxerui.rules.sources=<path>.ifc as a source file
name. That string is clang's spelling of a module reference
(-fmodule-file=<name>=<path>); MSVC takes /reference <name>=<path> as two
arguments, and /reference is absent here.
The same package builds with mcpp's default Windows toolchain (clang targeting
x86_64-pc-windows-msvc) and on Linux and macOS.
Shape of the project
# mcpp.toml
[toolchain]
windows = "msvc@system"
[build-dependencies]
huxerui-build-rules = { path = "mcpp/huxerui-build-rules", host-module = true, reexport = true }
huxerui-build-rules itself declares an inner host module:
# mcpp/huxerui-build-rules/mcpp.toml
[build-dependencies]
huxerui-source-select = { path = "../huxerui-source-select", host-module = true }
So the failing edge is the inner one: huxerui.rules is compiled with a
reference to huxerui.rules.sources, and that reference reaches cl.exe in
clang's syntax.
Environment
- mcpp 2026.9.10.2
- GitHub
windows-2022: VS 2022 Enterprise 17.14, VC tools 14.44.35207,
cl 19.44.35211
- Selected with
mcpp toolchain default msvc@system equivalent (manifest key)
Why it matters here
msvc@system is the way to reach import std; at c++20 on Windows while
#603 stands, and it is also the compiler the project's other
build system (CMake) uses, so selecting it would make the two agree. Both
motivations are blocked by this.
An earlier attempt on 2026.9.8.1 failed the same way at link rather than at
compile (LNK1104: cannot open file 'huxerui.rules=...ifc'), so the mis-spelled
reference appears on more than one command line.
Symptom
With
[toolchain] windows = "msvc@system", a package that has ahost-modulebuild-dependency fails while compiling the build program:
cl.exeis readinghuxerui.rules.sources=<path>.ifcas a source filename. That string is clang's spelling of a module reference
(
-fmodule-file=<name>=<path>); MSVC takes/reference <name>=<path>as twoarguments, and
/referenceis absent here.The same package builds with mcpp's default Windows toolchain (clang targeting
x86_64-pc-windows-msvc) and on Linux and macOS.Shape of the project
huxerui-build-rulesitself declares an inner host module:So the failing edge is the inner one:
huxerui.rulesis compiled with areference to
huxerui.rules.sources, and that reference reachescl.exeinclang's syntax.
Environment
windows-2022: VS 2022 Enterprise 17.14, VC tools 14.44.35207,cl19.44.35211mcpp toolchain default msvc@systemequivalent (manifest key)Why it matters here
msvc@systemis the way to reachimport std;at c++20 on Windows while#603 stands, and it is also the compiler the project's other
build system (CMake) uses, so selecting it would make the two agree. Both
motivations are blocked by this.
An earlier attempt on 2026.9.8.1 failed the same way at link rather than at
compile (
LNK1104: cannot open file 'huxerui.rules=...ifc'), so the mis-spelledreference appears on more than one command line.