mailarchive of the ptxdist mailing list
 help / color / mirror / Atom feed
From: Michael Olbrich <m.olbrich@pengutronix.de>
To: ptxdist@pengutronix.de
Cc: Lars Alex Pedersen <lapeddk@gmail.com>
Subject: Re: [ptxdist] [APPLIED] libgpiod: version bump 2.1.3 -> 2.2.2
Date: Wed, 30 Jul 2025 16:00:21 +0200	[thread overview]
Message-ID: <20250730140022.1391161-1-m.olbrich@pengutronix.de> (raw)
In-Reply-To: <20250717131139.167658-2-lapeddk@gmail.com>

Thanks, applied as b612b82df7c9901bfe2d649880d89d7d47a69212.

Michael

[sent from post-receive hook]

On Wed, 30 Jul 2025 16:00:21 +0200, Lars Alex Pedersen <lapeddk@gmail.com> wrote:
> * Add new options to install the dbus daemon with and without systemd.
> * Add gpio in group
> * Add gpio-manager user and group
> * Python binding now requires host pybuild and pip for build and
>   install, together with a patch to get the right build options
> * Removed ac_cv_prog_has_python_config line in rule, since it has been
>   fixed in this release
> * Configure options updated and reordered to match configure helper
> * New option --disable-introspection is removed by autogen.sh
> 
> https://git.kernel.org/pub/scm/libs/libgpiod/libgpiod.git/tree/NEWS?h=v2.2.2
> 
> Signed-off-by: Lars Alex Pedersen <lapeddk@gmail.com>
> Reviewed-by: Markus Heidelberg <m.heidelberg@cab.de>
> Message-Id: <20250717131139.167658-2-lapeddk@gmail.com>
> [mol: select HOST_PYTHON3 not HOST_SYSTEM_PYTHON3]
> Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
> 
> diff --git a/patches/libgpiod-2.2.2/0001-Add-ptxdist-python-compile-options.patch b/patches/libgpiod-2.2.2/0001-Add-ptxdist-python-compile-options.patch
> new file mode 100644
> index 000000000000..b8e8ebc04c8f
> --- /dev/null
> +++ b/patches/libgpiod-2.2.2/0001-Add-ptxdist-python-compile-options.patch
> @@ -0,0 +1,22 @@
> +From: Lars Alex Pedersen <laa@kamstrup.com>
> +Date: Thu, 10 Jul 2025 18:24:59 +0000
> +Subject: [PATCH] Add ptxdist python compile options
> +
> +Signed-off-by: Lars Alex Pedersen <laa@kamstrup.com>
> +---
> + bindings/python/Makefile.am | 2 +-
> + 1 file changed, 1 insertion(+), 1 deletion(-)
> +
> +diff --git a/bindings/python/Makefile.am b/bindings/python/Makefile.am
> +index 2ae8ac8a514c..ff1d677bba2a 100644
> +--- a/bindings/python/Makefile.am
> ++++ b/bindings/python/Makefile.am
> +@@ -36,7 +36,7 @@ clean-local:
> + all-local: python-tests
> + 	CFLAGS="-I$(abs_top_srcdir)/include/ -I$(abs_top_srcdir)/tests/gpiosim \
> + 	-L$(abs_top_builddir)/lib/.libs/ -L$(abs_top_builddir)/tests/gpiosim/.libs/" \
> +-	$(PYTHON) -m build
> ++	$(PYTHON) -m build --skip-dependency-check --wheel --no-isolation
> + 
> + install-exec-local:
> + 	$(PYTHON) -m pip install dist/*.whl \
> diff --git a/patches/libgpiod-2.2.2/autogen.sh b/patches/libgpiod-2.2.2/autogen.sh
> new file mode 120000
> index 000000000000..9f8a4cb7ddcb
> --- /dev/null
> +++ b/patches/libgpiod-2.2.2/autogen.sh
> @@ -0,0 +1 @@
> +../autogen.sh
> \ No newline at end of file
> diff --git a/patches/libgpiod-2.2.2/series b/patches/libgpiod-2.2.2/series
> new file mode 100644
> index 000000000000..c0b6f94781b7
> --- /dev/null
> +++ b/patches/libgpiod-2.2.2/series
> @@ -0,0 +1,4 @@
> +# generated by git-ptx-patches
> +#tag:base --start-number 1
> +0001-Add-ptxdist-python-compile-options.patch
> +# 34ebc65c9062276a316faee96d8f8775  - git-ptx-patches magic
> diff --git a/projectroot/etc/group b/projectroot/etc/group
> index 1a8e2eeb2342..176e211949d5 100644
> --- a/projectroot/etc/group
> +++ b/projectroot/etc/group
> @@ -39,4 +39,6 @@ seat:x:215:
>  pipewire:x:216:
>  mongodb:x:217:
>  polkitd:x:218:
> +gpio:x:219:
> +gpio-manager:x:220:gpio
>  nogroup:x:65534:
> diff --git a/projectroot/etc/passwd b/projectroot/etc/passwd
> index 89763295a55e..d6daf13c0269 100644
> --- a/projectroot/etc/passwd
> +++ b/projectroot/etc/passwd
> @@ -21,5 +21,6 @@ redis:x:212:213:redis:/dev/null:/bin/false
>  pipewire:x:213:216:pipewire:/dev/null:/bin/false
>  mongodb:x:214:217:mongodb:/dev/null:/bin/false
>  polkitd:x:215:218:polkitd:/dev/null:/bin/false
> +gpio-manager:x:216:220:gpio-manager:/dev/null:/bin/false
>  rpcuser:x:65533:65534:RPC user:/dev/null:/bin/false
>  nobody:x:65534:65534:Unprivileged Nobody:/dev/null:/bin/false
> diff --git a/rules/libgpiod.in b/rules/libgpiod.in
> index 94bff516477d..47ec2737653d 100644
> --- a/rules/libgpiod.in
> +++ b/rules/libgpiod.in
> @@ -3,9 +3,15 @@
>  menuconfig LIBGPIOD
>  	tristate
>  	prompt "libgpiod                      "
> -	select HOST_SYSTEM_PYTHON3
> -	select GCCLIBS_CXX	if LIBGPIOD_CXX
> -	select PYTHON3		if LIBGPIOD_PYTHON3
> +	select HOST_PYTHON3		if LIBGPIOD_PYTHON3
> +	select HOST_PYTHON3_PYBUILD	if LIBGPIOD_PYTHON3
> +	select HOST_PYTHON3_PIP		if LIBGPIOD_PYTHON3
> +	select HOST_AUTOTOOLS_AUTOCONF_ARCHIVE
> +	select DBUS			if LIBGPIOD_DBUS_DAEMON
> +	select LIBGUDEV			if LIBGPIOD_DBUS_DAEMON
> +	select GLIB			if LIBGPIOD_DBUS_DAEMON
> +	select GCCLIBS_CXX		if LIBGPIOD_CXX
> +	select PYTHON3			if LIBGPIOD_PYTHON3
>  	help
>  	  libgpiod is a library accompanied by a set of tools for
>  	  interacting with the Linux GPIO character device.
> @@ -57,6 +63,21 @@ config LIBGPIOD_GPIONOTIFY
>  	help
>  	  Waits for info changes on GPIO lines
>  
> +config LIBGPIOD_DBUS_DAEMON
> +	bool
> +	prompt "Install dbus daemon"
> +	help
> +	  Add a D-Bus interface to libgpiod together with a
> +	  daemon implementing it and a command-line client
> +
> +config LIBGPIOD_DBUS_DAEMON_SYSTEMD
> +	bool
> +	prompt "Install dbus daemon systemd files"
> +	depends on LIBGPIOD_DBUS_DAEMON
> +	depends on INITMETHOD_SYSTEMD
> +	help
> +	  Install dbus daemon systemd unit and udev files
> +
>  config LIBGPIOD_CXX
>  	bool
>  	prompt "Install C++ bindings"
> diff --git a/rules/libgpiod.make b/rules/libgpiod.make
> index 6272333b5613..73bf2acca68a 100644
> --- a/rules/libgpiod.make
> +++ b/rules/libgpiod.make
> @@ -14,8 +14,8 @@ PACKAGES-$(PTXCONF_LIBGPIOD) += libgpiod
>  #
>  # Paths and names
>  #
> -LIBGPIOD_VERSION	:= 2.1.3
> -LIBGPIOD_MD5		:= dd37487da746569b7311b2c8fd2f907d
> +LIBGPIOD_VERSION	:= 2.2.2
> +LIBGPIOD_MD5		:= 11e80ef978c7dbffc6f16dbac412ce42
>  LIBGPIOD		:= libgpiod-$(LIBGPIOD_VERSION)
>  LIBGPIOD_SUFFIX		:= tar.gz
>  LIBGPIOD_URL		:= https://www.kernel.org/pub/software/libs/libgpiod/$(LIBGPIOD).$(LIBGPIOD_SUFFIX)
> @@ -28,9 +28,23 @@ LIBGPIOD_LICENSE_FILES	:= \
>  	file://LICENSES/GPL-2.0-only.txt;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
>  	file://LICENSES/Linux-syscall-note.txt;md5=6b0dff741019b948dfe290c05d6f361c
>  
> +ifdef PTXCONF_LIBGPIOD_DBUS_DAEMON
> +LIBGPIOD_LICENSE	+= AND GPL-2.0-or-later AND CC-BY-SA-4.0
> +LIBGPIOD_LICENSE_FILES	+= \
> +	file://LICENSES/GPL-2.0-or-later.txt;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
> +	file://LICENSES/CC-BY-SA-4.0.txt;md5=fba3b94d88bfb9b81369b869a1e9a20f
> +else
>  ifdef PTXCONF_LIBGPIOD_TOOLS
>  LIBGPIOD_LICENSE	+= AND GPL-2.0-or-later
> -LIBGPIOD_LICENSE_FILES	+= file://LICENSES/GPL-2.0-or-later.txt;md5=b234ee4d69f5fce4486a80fdaf4a4263
> +LIBGPIOD_LICENSE_FILES	+= \
> +	file://LICENSES/GPL-2.0-or-later.txt;md5=b234ee4d69f5fce4486a80fdaf4a4263
> +endif
> +endif
> +
> +ifdef PTXCONF_LIBGPIOD_DBUS_DAEMON_SYSTEMD
> +LIBGPIOD_LICENSE	+= AND CC0-1.0
> +LIBGPIOD_LICENSE_FILES	+= \
> +	file://LICENSES/CC0-1.0.txt;md5=65d3616852dbf7b1a6d4b53b00626032
>  endif
>  
>  # ----------------------------------------------------------------------------
> @@ -47,22 +61,27 @@ LIBGPIOD_CONF_OPT	:= \
>  	--disable-examples \
>  	--$(call ptx/endis, PTXCONF_LIBGPIOD_CXX)-bindings-cxx \
>  	--$(call ptx/endis, PTXCONF_LIBGPIOD_PYTHON3)-bindings-python \
> -	--disable-bindings-rust
> +	--disable-bindings-rust \
> +	--$(call ptx/endis, PTXCONF_LIBGPIOD_DBUS_DAEMON)-dbus \
> +	--$(call ptx/endis, PTXCONF_LIBGPIOD_DBUS_DAEMON)-bindings-glib \
> +	--$(call ptx/endis, PTXCONF_LIBGPIOD_DBUS_DAEMON_SYSTEMD)-systemd
>  
>  LIBGPIOD_CONF_ENV := \
>  	$(CROSS_ENV) \
>  	$(if $(PTXCONF_LIBGPIOD_PYTHON3), \
> -		ac_cv_path_PYTHON=$(CROSS_PYTHON3) \
> -		ac_cv_prog_has_python_config=python$(PYTHON3_MAJORMINOR)-config)
> +	ac_cv_path_PYTHON=$(CROSS_PYTHON3)) \
> +	systemdsystemunitdir=/usr/lib/systemd/system
>  
>  LIBGPIOD_LDFLAGS:= -Wl,-rpath-link,$(LIBGPIOD_DIR)/lib/.libs
>  
> -LIBGPIOD_TOOLS-$(PTXCONF_LIBGPIOD_GPIODETECT)	+= gpiodetect
> -LIBGPIOD_TOOLS-$(PTXCONF_LIBGPIOD_GPIOINFO)	+= gpioinfo
> -LIBGPIOD_TOOLS-$(PTXCONF_LIBGPIOD_GPIOGET)	+= gpioget
> -LIBGPIOD_TOOLS-$(PTXCONF_LIBGPIOD_GPIOSET)	+= gpioset
> -LIBGPIOD_TOOLS-$(PTXCONF_LIBGPIOD_GPIOMON)	+= gpiomon
> -LIBGPIOD_TOOLS-$(PTXCONF_LIBGPIOD_GPIONOTIFY)	+= gpionotify
> +LIBGPIOD_BINS-$(PTXCONF_LIBGPIOD_GPIODETECT)	+= gpiodetect
> +LIBGPIOD_BINS-$(PTXCONF_LIBGPIOD_GPIOINFO)	+= gpioinfo
> +LIBGPIOD_BINS-$(PTXCONF_LIBGPIOD_GPIOGET)	+= gpioget
> +LIBGPIOD_BINS-$(PTXCONF_LIBGPIOD_GPIOSET)	+= gpioset
> +LIBGPIOD_BINS-$(PTXCONF_LIBGPIOD_GPIOMON)	+= gpiomon
> +LIBGPIOD_BINS-$(PTXCONF_LIBGPIOD_GPIONOTIFY)	+= gpionotify
> +LIBGPIOD_BINS-$(PTXCONF_LIBGPIOD_DBUS_DAEMON)	+= gpio-manager
> +LIBGPIOD_BINS-$(PTXCONF_LIBGPIOD_DBUS_DAEMON)	+= gpiocli
>  
>  # ----------------------------------------------------------------------------
>  # Target-Install
> @@ -79,11 +98,24 @@ $(STATEDIR)/libgpiod.targetinstall:
>  
>  	@$(call install_lib, libgpiod, 0, 0, 0644, libgpiod)
>  
> -	@for tool in $(LIBGPIOD_TOOLS-y); do \
> +	@for tool in $(LIBGPIOD_BINS-y); do \
>  		$(call install_copy, libgpiod, 0, 0, 0755, -, \
>  			/usr/bin/$$tool); \
>  	done
>  
> +ifdef PTXCONF_LIBGPIOD_DBUS_DAEMON
> +	@$(call install_tree, libgpiod, 0, 0, -, /usr/share/dbus-1/interfaces)
> +	@$(call install_tree, libgpiod, 0, 0, -, /etc/dbus-1/system.d)
> +	@$(call install_lib, libgpiod, 0, 0, 0644, libgpiodbus)
> +	@$(call install_lib, libgpiod, 0, 0, 0644, libgpiod-glib)
> +endif
> +ifdef PTXCONF_LIBGPIOD_DBUS_DAEMON_SYSTEMD
> +	@$(call install_tree, libgpiod, 0, 0, -, /usr/lib/udev/rules.d)
> +	@$(call install_alternative, libgpiod, 0, 0, 0644, \
> +		/usr/lib/systemd/system/gpio-manager.service)
> +	@$(call install_link, libgpiod, ../gpio-manager.service, \
> +		/usr/lib/systemd/system/multi-user.target.wants/gpio-manager.service)
> +endif
>  ifdef PTXCONF_LIBGPIOD_CXX
>  	@$(call install_lib, libgpiod, 0, 0, 0644, libgpiodcxx)
>  endif



  parent reply	other threads:[~2025-07-30 14:00 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-07-17 13:11 [ptxdist] [PATCH v5 1/2] host-python3-pip: Set dependency on host-python3-setuptools Lars Alex Pedersen
2025-07-17 13:11 ` [ptxdist] [PATCH v5 2/2] libgpiod: version bump 2.1.3 -> 2.2.2 Lars Alex Pedersen
2025-07-17 13:28   ` Markus Heidelberg via ptxdist
2025-07-30 14:00   ` Michael Olbrich [this message]
2025-07-30 14:00 ` [ptxdist] [APPLIED] host-python3-pip: Set dependency on host-python3-setuptools Michael Olbrich

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250730140022.1391161-1-m.olbrich@pengutronix.de \
    --to=m.olbrich@pengutronix.de \
    --cc=lapeddk@gmail.com \
    --cc=ptxdist@pengutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox