-
-
Notifications
You must be signed in to change notification settings - Fork 15.5k
clinfo: init at 2.2.18.04.06 #62872
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
clinfo: init at 2.2.18.04.06 #62872
Conversation
Aw man I was looking for this the other day, and was unhappy to find opencl-info seemed the best available. Thanks for the good timing! ;). |
pkgs/tools/system/clinfo/default.nix
Outdated
pname = "clinfo"; | ||
version = "2.2.18.04.06"; | ||
|
||
src = fetchurl { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You should use fetchFromGitHub
here.
pkgs/tools/system/clinfo/default.nix
Outdated
|
||
NIX_LDFLAGS = [ "-lOpenCL" ]; | ||
|
||
installPhase = '' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
makeFlags = [ "PREFIX=${placeholder "out"}" ];
should allow you to get rid of the custom installPhase
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can also just pass PREFIX=$(out) in this case, and Make will expand the environment variable $out.
Thanks for the review; I have fixed everything that was pointed out. |
Motivation for this change
clinfo
is the standard tool for querying the state of OpenCL. Nixpkgs already hasopencl-info
, but it's older and unmaintained.Things done
sandbox
innix.conf
on non-NixOS)nix-shell -p nix-review --run "nix-review wip"
./result/bin/
)nix path-info -S
before and after)