mirror of
https://github.com/vale981/poetry2nix
synced 2025-03-04 16:51:40 -05:00
Merge pull request #300 from purcell/overrides-for-qmk
Additional overrides for packages used by qmk
This commit is contained in:
commit
2d27d44397
1 changed files with 26 additions and 0 deletions
|
@ -369,6 +369,22 @@ self: super:
|
|||
) else old
|
||||
);
|
||||
|
||||
hid = super.hid.overridePythonAttrs (
|
||||
old: {
|
||||
postPatch = ''
|
||||
found=
|
||||
for name in libhidapi-hidraw libhidapi-libusb libhidapi-iohidmanager libhidapi; do
|
||||
full_path=${pkgs.hidapi.out}/lib/$name${pkgs.stdenv.hostPlatform.extensions.sharedLibrary}
|
||||
if test -f $full_path; then
|
||||
found=t
|
||||
sed -i -e "s|'$name\..*'|'$full_path'|" hid/__init__.py
|
||||
fi
|
||||
done
|
||||
test -n "$found" || { echo "ERROR: No known libraries found in ${pkgs.hidapi.out}/lib, please update/fix this build expression."; exit 1; }
|
||||
'';
|
||||
}
|
||||
);
|
||||
|
||||
horovod = super.horovod.overridePythonAttrs (
|
||||
old: {
|
||||
propagatedBuildInputs = (old.propagatedBuildInputs or [ ]) ++ [ pkgs.mpi ];
|
||||
|
@ -1286,6 +1302,16 @@ self: super:
|
|||
}
|
||||
);
|
||||
|
||||
pyusb = super.pyusb.overridePythonAttrs (
|
||||
old: {
|
||||
postPatch = ''
|
||||
libusb=${pkgs.libusb1.out}/lib/libusb-1.0${pkgs.stdenv.hostPlatform.extensions.sharedLibrary}
|
||||
test -f $libusb || { echo "ERROR: $libusb doesn't exist, please update/fix this build expression."; exit 1; }
|
||||
sed -i -e "s|find_library=None|find_library=lambda _:\"$libusb\"|" usb/backend/libusb1.py
|
||||
'';
|
||||
}
|
||||
);
|
||||
|
||||
pyzmq = super.pyzmq.overridePythonAttrs (
|
||||
old: {
|
||||
nativeBuildInputs = (old.nativeBuildInputs or [ ]) ++ [ pkgs.pkg-config ];
|
||||
|
|
Loading…
Add table
Reference in a new issue