On 2021-11-16 11:50 pm, Jean Abou Samra wrote:
Could it be that you are building in WSL?
Yes, although WSL != MinG.
tl;dr: I need to switch to WSL version 2.
----
There is an important distinction between the WSL versions. WSL1 builds
upon some clever machinery within the NT kernel. Each Linux process
gets encapsulated as a so-called "pico process" in NT and runs against a
Linux kernel façade that maps systems calls to the NT kernel. With a
custom file system to map it to Windows proper, most Linux programs run
as expected with no virtualization. However, Microsoft always warned
developers that some things might not work. To date, I had never had
issues running LilyPond.
In contrast, WSL2 sits upon Hyper-V to virtualize a real Linux kernel,
so there is no longer a need to map system calls. There is, however, a
noted performance penalty when Linux processes need to access the
Windows file system, and Microsoft recommends that folks needing to do
lots of I/O between the two file systems should stay on WSL1. For
everyone else, WSL2 should result in virtually perfect compatibility as
well as better performance when processes run entirely within the Linux
environment.
WSL2 was not option for me as it required a newer release of Windows 10
that my computer was blocked from installing. Eventually, Intel got
around to releasing updated drivers for my chipset which unblocked
Windows Update. But enough time had passed that I never bothered to
upgrade to WSL2, especially given WSL1 was doing the job.
Seeing this issue made me recall the early days of WSL1 and some of the
quirks people were discovering. To get a point of comparison, I
installed a second Ubuntu distribution and upgraded it to WSL2. And the
end result is that I cannot reproduce the error when running the tests.
As such, I think we can safely resolve this issue external to LilyPond.
For folks finding this thread in the future, switch to WSL2 if you can.
Otherwise, reduce the build workload to not trigger the faulty behavior
in WSL1.
My apologies for surfacing this noise to the development team.
-- Aaron Hill