Closed
Description
The same dummy "hello world" project + sccache does not work for rustc 1.48 but works for 1.47.
Here's a minimal example:
Create the script locally:
#! /usr/bin/env bash
set -e
set -x
env USER=test-user cargo new test-project --bin
cd test-project
echo "Running without sccache"
cargo run
cargo clean
cargo install sccache
echo "Running with sccache"
RUSTC_WRAPPER="/usr/local/cargo/bin/sccache" cargo run
sccache -s
and then run it in Docker:
docker run --rm -v $(pwd)/test-sccache.sh:/test-sccache.sh rust:1.47 /test-sccache.sh
docker run --rm -v $(pwd)/test-sccache.sh:/test-sccache.sh rust:1.48 /test-sccache.sh
Expected: both runs work identically and finish successfully
Actual: 1.47 version works as expected, 1.48 version fails on the RUSTC_WRAPPER="/usr/local/cargo/bin/sccache" cargo run
step:
Running with sccache
+ echo 'Running with sccache'
+ RUSTC_WRAPPER=/usr/local/cargo/bin/sccache
+ cargo run
error: failed to run `rustc` to learn about target-specific information
Caused by:
process didn't exit successfully: `/usr/local/cargo/bin/sccache rustc - --crate-name ___ --print=file-names --crate-type bin --crate-type rlib --crate-type dylib --crate-type cdylib --crate-type staticlib --crate-type proc-macro --print=sysroot --print=cfg` (exit code: 2)
--- stderr
error: failed to execute compile
caused by: Failed to send data to or receive data from server
caused by: Failed to read response header
caused by: failed to fill whole buffer
Metadata
Metadata
Assignees
Labels
No labels