2021-09-18 10:52:07 +00:00
|
|
|
{ lib, buildPythonPackage, fetchFromGitHub, glfw3 }:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "glfw";
|
2021-12-24 04:21:11 +00:00
|
|
|
version = "2.5.0";
|
2021-09-18 10:52:07 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "FlorianRhiem";
|
|
|
|
repo = "pyGLFW";
|
|
|
|
rev = "v${version}";
|
2021-12-24 04:21:11 +00:00
|
|
|
sha256 = "15kk0zhhja0yqah09wzpg6912zd5bjmk84ab1n5nwryicpg44hqk";
|
2021-09-18 10:52:07 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
# Patch path to GLFW shared object
|
|
|
|
patches = [ ./search-path.patch ];
|
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace glfw/library.py --replace "@GLFW@" '${glfw3}/lib'
|
|
|
|
'';
|
|
|
|
propagatedBuildInputs = [ glfw3 ];
|
|
|
|
|
|
|
|
# Project has no tests
|
|
|
|
doCheck = false;
|
|
|
|
pythonImportsCheck = [ "glfw" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Python bindings for GLFW";
|
|
|
|
homepage = "https://github.com/FlorianRhiem/pyGLFW";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = [ maintainers.McSinyx ];
|
|
|
|
};
|
|
|
|
}
|