[libcxx-commits] [PATCH] D97166: [libcxx] [docs] Update docs about how to build for Windows
Martin Storsjö via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Mon Feb 22 14:27:25 PST 2021
mstorsjo added inline comments.
Comment at: libcxx/docs/BuildingLibcxx.rst:111
+`\msys64\msys2_shell.cmd -full-path -mingw64` (preserving the earlier
+environment, allowing the MSVC headers/libraries and clang-cl to be found).
> mstorsjo wrote:
> > @rnk - Does this match how you generally build/run tests for other llvm components these days, or do you use some other provider of a unix shell, or do the rest of the tests cope with just a plain cmd shell?
> > At least for the libcxx tests, running tests in a cmd shell errors out like this:
> > ```
> > Script:
> > --
> > echo 'COMPILED WITH' > nul && 'C:/Program Files/LLVM/bin\clang++.EXE' ...
> > --
> > Exit Code: 9009
> > Command Output (stderr):
> > --
> > ''C:' is not recognized as an internal or external command,
> > operable program or batch file.
> > ```
> Yes, this is pretty close to what I do. I usually develop in bash, and then bash is on PATH, and most lit tests succeed that way. The codepath where lit invokes cmd to run tests is not maintained, and should ideally be removed.
> However, you are probably aware that all of the other lit test suites in LLVM avoid the use of a shell altogether, instead using the lit internal shell. At the time, skipping the extra shell subprocess in every test saved a lot of time for me, so I put a fair amount of effort into migrating to the internal shell. It might be worth doing the same for libc++, but I haven't looked into it at all.
Thanks for confirming!
Yeah there's certainly lots to improve in running the libcxx tests on windows too, but the major issue is getting the tests back into a working shape overall - right now there's at least two that more or less block all tests from functioning, the `npos` issue, and D97167. And overall getting it into a more reproducible setup where more than one individual can plausibly run them...
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
More information about the libcxx-commits