Trying to use sccache's toolchain packaging with nixOS's gcc-wrapper fails, trying to do so manually gives the following error:
sccache: error: Failed to analyse /nix/store/dkw46jgi8i0bq64cag95v4ywz6g9bnga-gcc-wrapper-11.3.0/bin/gcc with ldd
sccache: caused by: Elf magic not found
This is because the gcc in gcc-wrapper is in fact a shell script which sets the environment and then runs gcc.
One possible solution would be to allow for the disabling of toolchain packaging, as with the way nixOS works, and the way our machines are set up, we'd have the exact same toolchain even without packaging.
Trying to use sccache's toolchain packaging with nixOS's gcc-wrapper fails, trying to do so manually gives the following error:
This is because the gcc in gcc-wrapper is in fact a shell script which sets the environment and then runs gcc.
One possible solution would be to allow for the disabling of toolchain packaging, as with the way nixOS works, and the way our machines are set up, we'd have the exact same toolchain even without packaging.