Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

esptool: 2.7 -> 3.0, fix #82965 #107389

Merged
merged 1 commit into from
Dec 22, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 18 additions & 4 deletions pkgs/tools/misc/esptool/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,31 @@

python3.pkgs.buildPythonApplication rec {
pname = "esptool";
version = "2.7";
version = "3.0";

src = fetchFromGitHub {
owner = "espressif";
repo = "esptool";
rev = "v${version}";
sha256 = "1p5hx0rhs986ffqz78rdxg7jayndsq632399xby39k17kvd3mb31";
sha256 = "1y022qlcdgdx5a88lkc3sqavklz494afbfyh100lp7xfk3f2mjln";
};

checkInputs = with python3.pkgs; [ flake8 flake8-future-import flake8-import-order openssl ];
propagatedBuildInputs = with python3.pkgs; [ pyserial pyaes ecdsa ];
checkInputs = with python3.pkgs;
[ flake8 flake8-future-import flake8-import-order openssl ];
propagatedBuildInputs = with python3.pkgs;
[ pyserial pyaes ecdsa reedsolo bitstring cryptography ];

# wrapPythonPrograms will overwrite esptool.py with a bash script,
# but espefuse.py tries to import it. Since we don't add any binary paths,
# use patchPythonScript directly.
dontWrapPythonPrograms = true;
postFixup = ''
buildPythonPath "$out $pythonPath"
for f in $out/bin/*.py; do
echo "Patching $f"
patchPythonScript "$f"
done
'';

meta = with stdenv.lib; {
description = "ESP8266 and ESP32 serial bootloader utility";
Expand Down