cudaPackages.cuda_nvcc: wrap binary so NVCC can always find compiler#465329
cudaPackages.cuda_nvcc: wrap binary so NVCC can always find compiler#465329SomeoneSerge merged 1 commit intoNixOS:masterfrom
Conversation
Signed-off-by: Connor Baker <ConnorBaker01@gmail.com>
029a8fc to
2fe0be4
Compare
| @@ -92,8 +92,6 @@ setupCUDAToolkitCompilers() { | |||
| export CUDAHOSTCXX="@ccFullPath@" | |||
There was a problem hiding this comment.
Probably want to break up the hook's dependency on the cc too 🤔 Because now we have 3 references all from different places
|
|
||
| # Fix a compatible backend compiler | ||
| PATH += "${backendStdenv.cc}/bin": | ||
| compiler-bindir = ${backendStdenv.cc}/bin |
There was a problem hiding this comment.
Ah damn this is off by 1 again: nvcc here is hostTarget, and cc - buildHost
There was a problem hiding this comment.
OTOH, we never made cross actually work, might as well postpone the larping
There was a problem hiding this comment.
cc is unspliced but backendStdenv is spliced and from pkgsHostTarget (the default package set drawn from by callPackage) so I would hope cc is also from hostTarget.
There was a problem hiding this comment.
Nooo that's the thing about stdenvs, they're always offset by -1:
$ nix eval -f "<nixpkgs>" --argstr crossSystem aarch64-linux stdenv.cc.name
"aarch64-unknown-linux-gnu-gcc-wrapper-14.3.0"But maybe we should merge regardless and fix whenever
compiler-bindirinnvcc.profileinstead of insetupCudaHookso it is always set, even when NVCC is run in ad-hoc fashion in installed environments rather than insidemkDerivation.These changes needed to be made to allow the tests for pycuda (#465047) to work.
I was able to build
python3Packages.onnxruntimeandfirefoxwith:Things done
passthru.tests.nixpkgs-reviewon this PR. See nixpkgs-review usage../result/bin/.Add a 👍 reaction to pull requests you find important.