Merge pull request #188197 from sersorrel/screeninfo-libs

This commit is contained in:
Sandro 2022-08-31 17:38:00 +02:00 committed by GitHub
commit a664533134
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -25,11 +25,14 @@ buildPythonApplication rec {
dataclasses
];
buildInputs = [
libX11
libXinerama
libXrandr
];
postPatch = ''
substituteInPlace screeninfo/enumerators/xinerama.py \
--replace 'load_library("X11")' 'ctypes.cdll.LoadLibrary("${libX11}/lib/libX11.so")' \
--replace 'load_library("Xinerama")' 'ctypes.cdll.LoadLibrary("${libXinerama}/lib/libXinerama.so")'
substituteInPlace screeninfo/enumerators/xrandr.py \
--replace 'load_library("X11")' 'ctypes.cdll.LoadLibrary("${libX11}/lib/libX11.so")' \
--replace 'load_library("Xrandr")' 'ctypes.cdll.LoadLibrary("${libXrandr}/lib/libXrandr.so")'
'';
checkInputs = [
pytestCheckHook