On Wed, May 22, 2024 at 11:15:42PM +0200, Roland Hieber wrote:
> Signed-off-by: Roland Hieber <r...@pengutronix.de>
> ---
>  rules/python3-periphery.in   | 10 +++++++
>  rules/python3-periphery.make | 55 ++++++++++++++++++++++++++++++++++++
>  2 files changed, 65 insertions(+)
>  create mode 100644 rules/python3-periphery.in
>  create mode 100644 rules/python3-periphery.make
> 
> diff --git a/rules/python3-periphery.in b/rules/python3-periphery.in
> new file mode 100644
> index 000000000000..41a626acebce
> --- /dev/null
> +++ b/rules/python3-periphery.in
> @@ -0,0 +1,10 @@
> +## SECTION=python3
> +
> +config PYTHON3_PERIPHERY
> +     tristate
> +     select HOST_SYSTEM_PYTHON3_SETUPTOOLS

No. The PYTHON3 dependency already includes the correct setuptools.

Michael

> +     select PYTHON3
> +     prompt "periphery"
> +     help
> +       A pure Python library for peripheral I/O (GPIO, LED, PWM, SPI, I2C,
> +       MMIO, Serial) in Linux.
> diff --git a/rules/python3-periphery.make b/rules/python3-periphery.make
> new file mode 100644
> index 000000000000..9f0ace01feea
> --- /dev/null
> +++ b/rules/python3-periphery.make
> @@ -0,0 +1,55 @@
> +# -*-makefile-*-
> +#
> +# Copyright (C) 2024 by Roland Hieber <r...@pengutronix.de>
> +#
> +# For further information about the PTXdist project and license conditions
> +# see the README file.
> +#
> +
> +#
> +# We provide this package
> +#
> +PACKAGES-$(PTXCONF_PYTHON3_PERIPHERY) += python3-periphery
> +
> +#
> +# Paths and names
> +#
> +PYTHON3_PERIPHERY_VERSION    := 2.4.1
> +PYTHON3_PERIPHERY_MD5                := 2b2a1037fb4ac15e7b0514ce3659d26c
> +PYTHON3_PERIPHERY            := python-periphery-$(PYTHON3_PERIPHERY_VERSION)
> +PYTHON3_PERIPHERY_SUFFIX     := tar.gz
> +PYTHON3_PERIPHERY_URL                := $(call ptx/mirror-pypi, 
> python-periphery, $(PYTHON3_PERIPHERY).$(PYTHON3_PERIPHERY_SUFFIX))
> +PYTHON3_PERIPHERY_SOURCE     := 
> $(SRCDIR)/$(PYTHON3_PERIPHERY).$(PYTHON3_PERIPHERY_SUFFIX)
> +PYTHON3_PERIPHERY_DIR                := $(BUILDDIR)/$(PYTHON3_PERIPHERY)
> +PYTHON3_PERIPHERY_LICENSE    := MIT
> +PYTHON3_PERIPHERY_LICENSE_FILES      := \
> +     
> file://README.md;startline=202;endline=204;md5=bc9620815782faae308ef7bcf23bcecb
>  \
> +     file://LICENSE;md5=30fe6f023a80fb33989fb3b9d773fea0
> +
> +# 
> ----------------------------------------------------------------------------
> +# Prepare
> +# 
> ----------------------------------------------------------------------------
> +
> +PYTHON3_PERIPHERY_CONF_TOOL  := python3
> +
> +# 
> ----------------------------------------------------------------------------
> +# Target-Install
> +# 
> ----------------------------------------------------------------------------
> +
> +$(STATEDIR)/python3-periphery.targetinstall:
> +     @$(call targetinfo)
> +
> +     @$(call install_init, python3-periphery)
> +     @$(call install_fixup, python3-periphery,PRIORITY,optional)
> +     @$(call install_fixup, python3-periphery,SECTION,base)
> +     @$(call install_fixup, python3-periphery,AUTHOR,"Roland Hieber 
> <r...@pengutronix.de>")
> +     @$(call install_fixup, python3-periphery,DESCRIPTION,missing)
> +
> +     @$(call install_glob, python3-periphery, 0, 0, -, \
> +             $(PYTHON3_SITEPACKAGES),, *.py)
> +
> +     @$(call install_finish, python3-periphery)
> +
> +     @$(call touch)
> +
> +# vim: syntax=make
> -- 
> 2.39.2
> 
> 
> 

-- 
Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | http://www.pengutronix.de/  |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

Reply via email to