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
ledger: enable python command #39919
Conversation
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec { | |||
|
|||
enableParallelBuilding = true; | |||
|
|||
cmakeFlags = [ "-DCMAKE_INSTALL_LIBDIR=lib" ]; | |||
cmakeFlags = [ "-DCMAKE_INSTALL_LIBDIR=lib" "-DUSE_PYTHON=true" ]; |
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.
Can we turn this into a package option?
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.
Sadly, I wouldn't know how.
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'd add a parameter to the input of the function which is true by default: {... usePython ? true ... }:
then you'd check it in the cmakeFlags
like this: (if usePython then "-DUSE_PYTHON=true" else "");
or you'd use (lib.optionalString usePython "-DUSE_PYTHON=true")
.
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.
Oh, easy enough. I'll update the PR.
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.
Done
ledger in nixpkgs currently uses python (it’s in buildInputs), but the ledger python command isn’t available until you turn it on via a cmake flag.
d428ea3
to
b62788f
Compare
@GrahamcOfBorg build ledger |
Success on x86_64-linux (full log) Attempted: ledger Partial log (click to expand)
|
Success on aarch64-linux (full log) Attempted: ledger Partial log (click to expand)
|
Success on x86_64-darwin (full log) Attempted: ledger Partial log (click to expand)
|
Motivation for this change
ledger in nixpkgs currently uses python (it’s in
buildInputs
), but theledger python command isn’t available until you turn it on via a cmake
flag.
Things done
build-use-sandbox
innix.conf
on non-NixOS)nix-shell -p nox --run "nox-review wip"
./result/bin/
)