2021-01-15 22:18:51 +00:00
|
|
|
{ lib, stdenv, python3Packages, fetchFromGitHub }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
python3Packages.buildPythonApplication rec {
|
2021-01-05 17:05:55 +00:00
|
|
|
pname = "printrun";
|
2021-01-15 22:18:51 +00:00
|
|
|
version = "2.0.0rc5";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "kliment";
|
|
|
|
repo = "Printrun";
|
2021-01-05 17:05:55 +00:00
|
|
|
rev = "${pname}-${version}";
|
2021-01-15 22:18:51 +00:00
|
|
|
sha256 = "179x8lwrw2h7cxnkq7izny6qcb4nhjnd8zx893i77zfhzsa6kx81";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
propagatedBuildInputs = with python3Packages; [
|
|
|
|
appdirs cython dbus-python numpy six wxPython_4_0 psutil pyglet pyopengl pyserial
|
2020-04-24 23:36:52 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
setupPyBuildFlags = ["-i"];
|
|
|
|
|
|
|
|
postPatch = ''
|
|
|
|
sed -i -r "s|/usr(/local)?/share/|$out/share/|g" printrun/utils.py
|
|
|
|
'';
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
for f in $out/share/applications/*.desktop; do
|
|
|
|
sed -i -e "s|/usr/|$out/|g" "$f"
|
|
|
|
done
|
|
|
|
'';
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Pronterface, Pronsole, and Printcore - Pure Python 3d printing host software";
|
|
|
|
homepage = "https://github.com/kliment/Printrun";
|
|
|
|
license = licenses.gpl3;
|
|
|
|
platforms = platforms.linux;
|
|
|
|
};
|
|
|
|
}
|