Merge pull request #192067 from SuperSandro2000/klipper
This commit is contained in:
commit
aba7db9b9c
1 changed files with 8 additions and 6 deletions
|
@ -4,6 +4,7 @@
|
||||||
, python3
|
, python3
|
||||||
, unstableGitUpdater
|
, unstableGitUpdater
|
||||||
}:
|
}:
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
pname = "klipper";
|
pname = "klipper";
|
||||||
version = "unstable-2022-09-11";
|
version = "unstable-2022-09-11";
|
||||||
|
@ -23,13 +24,14 @@ stdenv.mkDerivation rec {
|
||||||
buildInputs = [ (python3.withPackages (p: with p; [ cffi pyserial greenlet jinja2 markupsafe ])) ];
|
buildInputs = [ (python3.withPackages (p: with p; [ cffi pyserial greenlet jinja2 markupsafe ])) ];
|
||||||
|
|
||||||
# we need to run this to prebuild the chelper.
|
# we need to run this to prebuild the chelper.
|
||||||
postBuild = "python ./chelper/__init__.py";
|
postBuild = ''
|
||||||
|
python ./chelper/__init__.py
|
||||||
|
'';
|
||||||
|
|
||||||
# 2022-06-28: Python 3 is already supported in klipper, alas shebangs remained
|
# Python 3 is already supported but shebangs aren't updated yet
|
||||||
# the same - we replace them in patchPhase.
|
postPatch = ''
|
||||||
patchPhase = ''
|
for file in klippy.py console.py parsedump.py; do
|
||||||
for F in klippy.py console.py parsedump.py; do
|
substituteInPlace $file \
|
||||||
substituteInPlace $F \
|
|
||||||
--replace '/usr/bin/env python2' '/usr/bin/env python'
|
--replace '/usr/bin/env python2' '/usr/bin/env python'
|
||||||
done
|
done
|
||||||
'';
|
'';
|
||||||
|
|
Loading…
Reference in a new issue