Repository navigation
Build failures in WSL Ubuntu #41459
Description
Activity
- addedbuildIssues and PRs related to Node.js builds or CI infrastructure.Issues and PRs related to Node.js builds or CI infrastructure.wslIssues and PRs related to the Windows Subsystem for Linux.Issues and PRs related to the Windows Subsystem for Linux.
on Jan 10, 2022 Tried with a different flavor of ubuntu wsl and it above error is not showing unless we use
sudo.But, if we are running without
sudo, error will be as below:: not found: 2: : not found: 1: Node.js configure: Found Python 3.8.10... Traceback (most recent call last): File "./configure", line 27, in <module> import configure File "/mnt/e/OpenSource/node/configure.py", line 1981, in <module> os.chmod('config.status', 0o775) PermissionError: [Errno 1] Operation not permitted: 'config.status'Figured out that the issue is from
run_gypAnd finally, 2 hours of reverse engineering, helped me to figure out the issue.
https://github.com/nodejs/node/blob/master/configure.py#L2041 - calling the
run_gyp->...->...->tools/gyp/pylib/gyp/input.pywas throwing the errorraise GypError(f"{build_file_path} not found (cwd: {os.getcwd()})")The reason for this issue is from
configure.pycallingrun_gyp()with some carriage returns (\r\r).https://github.com/nodejs/node/blob/master/configure.py#L2035 - In this line, the
\r\ris being added.Once I commented out the code
#gyp_args += args, all went well.- added a commit that references this issue
on Jan 11, 2022 Pull request created
- added a commit that references this issue
on Jan 16, 2022 - added a commit that references this issue
on Feb 1, 2022 - added a commit that references this issue
on May 22, 2026
Version
latest
Platform
Linux 5.10.16.3-microsoft-standard-WSL2
#1SMP Fri Apr 2 22:23:49 UTC 2021 x86_64 x86_64 x86_64 GNU/LinuxSubsystem
build
What steps will reproduce the bug?
Fresh checkout on a WSL Ubuntu.
run
sh ./configureand observe an error as below:Screenshot:

How often does it reproduce? Is there a required condition?
Always in normal conditions.
What is the expected behavior?
Configure should be success as per the Build docs
What do you see instead?
Error and exit the process
Additional information
No response