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
kmsxx and pykms: init at 2017-10-03 #30167
Conversation
|
||
nativeBuildInputs = [ cmake pkgconfig ]; | ||
buildInputs = [ libdrm ] ++ stdenv.lib.optional (pythonBindings != null) pythonBindings; | ||
|
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.
in order for it to be discoverable by python.buildEnv
, it needs
pythonPath = [ ];
Furthermore, it would be good to add
passthru.python = pythonBindings;
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.
optional (pythonBindings != null) ?
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.
@FRidh Sorry, don't understand. You said we should build python bindings in any case.
@@ -0,0 +1,27 @@ | |||
{ stdenv, fetchgit, cmake, pkgconfig, libdrm, pythonBindings ? null }: |
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.
I suggest to just pass in python
and build the bindings regardless. We could (perhaps later) put them in a separate output.
pkgs/top-level/python-packages.nix
Outdated
@@ -15595,6 +15595,10 @@ in { | |||
pika-pool = callPackage ../development/python-modules/pika-pool { }; | |||
platformio = callPackage ../development/python-modules/platformio { }; | |||
|
|||
pykms = callPackage ../development/libraries/kmsxx { | |||
pythonBindings = python; |
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.
The manual says
Dependencies:
- libdrm
- Python 3.x (for python bindings)
...so it should be disabled for Python 2.x.
Nevermind: tomba/kmsxx@643d678
stdenv.mkDerivation rec { | ||
name = "kmsxx-2017-10-03"; | ||
|
||
src = fetchgit { |
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 use fetchFromGitHub
with fetchSubModules
.
description = "C++11 library, utilities and python bindings for Linux kernel mode setting"; | ||
homepage = https://github.com/tomba/kmsxx; | ||
license = licenses.mpl20; | ||
maintainers = [ maintainers.gnidorah ]; |
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.
nitpack alert: maintainers = with maintainers; [ gnidorah ];
pkgs/top-level/python-packages.nix
Outdated
@@ -15595,6 +15595,8 @@ in { | |||
pika-pool = callPackage ../development/python-modules/pika-pool { }; | |||
platformio = callPackage ../development/python-modules/platformio { }; | |||
|
|||
pykms = callPackage ../development/libraries/kmsxx { }; |
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.
We are already using pykms
for something else although it's not under pythonPackages
.
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.
@peterhoeg ?
$ grep -Ir pykms | grep -v .git
pkgs/top-level/python-packages.nix: pykms = callPackage ../development/libraries/kmsxx { };
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.
@peterhoeg Ok, seeing it after rebase. But that's another package. Need to do something with name.
Thanks! |
Motivation for this change
Things done
build-use-sandbox
innix.conf
on non-NixOS)nix-shell -p nox --run "nox-review wip"
./result/bin/
)