HomeAssistantRepository/dev-embedded/esptool/esptool-3.3.1.ebuild

43 lines
1.1 KiB
Bash

# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
PYTHON_COMPAT=( python3_{9..11} )
inherit distutils-r1
DESCRIPTION="A serial utility to communicate & flash code to Espressif ESP8266 & ESP32 chips."
HOMEPAGE="https://github.com/espressif/esptool https://pypi.org/project/esptool/"
SRC_URI="mirror://pypi/${P:0:1}/${PN}/${P}.tar.gz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="amd64 arm arm64 x86"
IUSE="test"
RESTRICT="!test? ( test )"
DOCS="README.md"
RDEPEND=">=dev-python/bitstring-3.1.6[${PYTHON_USEDEP}]
>=dev-python/cryptography-2.1.4[${PYTHON_USEDEP}]
>=dev-python/ecdsa-0.16.0[${PYTHON_USEDEP}]
>=dev-python/pyserial-3.0[${PYTHON_USEDEP}]
>=dev-python/reedsolomon-1.5.3[${PYTHON_USEDEP}]"
BDEPEND="
dev-python/setuptools[${PYTHON_USEDEP}]
dev-python/pip[${PYTHON_USEDEP}]
dev-python/wheel[${PYTHON_USEDEP}]
test? (
dev-python/pytest[${PYTHON_USEDEP}]
dev-python/unittest[${PYTHON_USEDEP}]
)"
# reedsolo>=1.5.3,<=1.5.4
src_prepare() {
sed -i "s/reedsolo>=1.5.3,<=1.5.4/reedsolo>=1.5.3/g" -i setup.py || die
eapply_user
}
distutils_enable_tests unittest