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

cargo compiling error 122 on windows 7 x64 platform #52377

Closed
jeppeter opened this issue Jul 14, 2018 · 6 comments
Closed

cargo compiling error 122 on windows 7 x64 platform #52377

jeppeter opened this issue Jul 14, 2018 · 6 comments
Labels
A-incr-comp Area: Incremental compilation O-windows Operating system: Windows O-windows-7 OS: Windows 7 or Windows Server 2008 R2 or etc. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Comments

@jeppeter
Copy link

jeppeter commented Jul 14, 2018

To whom responsible for this:
I download https://static.rust-lang.org/dist/rust-1.27.1-x86_64-pc-windows-msvc.msi
and install on my windows 7 sp1 x64 , I select insert rust path into PATH environment variable , when i run cargo new hello and cargo build it is error ,(see attachment) the most eror is os error 122 , first i guess ,the compiler is not in the right environment ,but when i run command
rustc main.rs
it compiles ok ,so i am sure that the cargo and rustc not run in proper way ,
and i set the environment variable CARGO_INCREMENTAL=0
this makes ok

could somebody fixup this bug
thank you
best regards
error.txt

@retep998
Copy link
Member

retep998 commented Jul 15, 2018

What kind of drive is Z:? Is it a network drive? Is it a ram drive?

Related issue: #48249

@jeppeter
Copy link
Author

jeppeter commented Jul 15, 2018 via email

@retep998
Copy link
Member

Please do all your Rust stuff on a normal drive, not a virtual memory drive, until this bug can be fixed.

@jonas-schievink
Copy link
Contributor

Inlining error.txt so people don't have to download and open it:

   Compiling hello v0.1.0 (file:///Z:/hello)
error: incremental compilation: error canonicalizing path `Z:\hello\target\debug\incremental\hello-2tm11x4hww51g`: 传递给系统调用的数据区域太小。 (os error 122)

thread 'rustc' panicked at 'librustc\session\mod.rs:727: Trying to get session directory from IncrCompSession `NotInitialized`', librustc\session\mod.rs:1180:26
note: Run with `RUST_BACKTRACE=1` for a backtrace.

error: internal compiler error: unexpected panic

note: the compiler unexpectedly panicked. this is a bug.

note: we would appreciate a bug report: https://github.com/rust-lang/rust/blob/master/CONTRIBUTING.md#bug-reports

note: rustc 1.25.0 (84203cac6 2018-03-25) running on x86_64-pc-windows-msvc

error: Could not compile `hello`.

To learn more, run the command again with --verbose.

@jonas-schievink
Copy link
Contributor

Error 122 is ERROR_INSUFFICIENT_BUFFER.

@Noratrieb Noratrieb added the T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. label Apr 5, 2023
@workingjubilee workingjubilee added the O-windows-7 OS: Windows 7 or Windows Server 2008 R2 or etc. label Jul 22, 2023
@Enselic
Copy link
Member

Enselic commented Aug 21, 2023

Triage: This is about problems canonicalizing paths on RAM drives. So is #48249, so closing as duplicate.

@Enselic Enselic closed this as not planned Won't fix, can't repro, duplicate, stale Aug 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-incr-comp Area: Incremental compilation O-windows Operating system: Windows O-windows-7 OS: Windows 7 or Windows Server 2008 R2 or etc. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

No branches or pull requests

7 participants