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

bootstrap dist command is trying to run unix date command on a windows system #47908

Closed
onur opened this issue Jan 31, 2018 · 1 comment
Closed
Labels
C-bug Category: This is a bug. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)

Comments

@onur
Copy link
Member

onur commented Jan 31, 2018

This issue is currently blocking me to upgrade rustc on docs.rs.

When I try to run python x.py dist, bootstrap is failing with following output:

Dist rustc stage2 (i686-pc-windows-msvc)


failed to execute command: "date" "+%B %Y"
error: The system cannot find the file specified. (os error 2)


failed to run: c:\rust\build\bootstrap\debug\bootstrap --config debian\config-win32.toml dist
Build completed unsuccessfully in 0:01:24

Windows doesn't have a date executable. I tried to copy MSYS's date (along with all dependencies) to $PATH, it worked for x86_64-pc-windows-msvc but still failing on i686-pc-windows-msvc.

date command is being called in src/bootstrap/dist.rs#L450-L451. It should be fairly easy to replace this with time crate.

@Mark-Simulacrum Mark-Simulacrum added C-bug Category: This is a bug. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) labels Jan 31, 2018
@ghost
Copy link

ghost commented Feb 1, 2018

I'll take this!

kennytm added a commit to kennytm/rust that referenced this issue Feb 6, 2018
…alexcrichton

Use time crate in bootstrap dist instead of date

`bootstrap dist` command is trying to run *NIX specific `date` command to get current month and year. This command keep failing when it's called on a Windows command prompt. This patch is making it use time crate.

Closes: rust-lang#47908
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Category: This is a bug. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)
Projects
None yet
Development

No branches or pull requests

2 participants