Skip to contentSkip to conversation

libgpiod: detail package licensing

PATCH In review [email protected] 2 participants 6 messages Sep 29

lore
Share & tools
lore
#0 lore raw

v4 cover libgpiod: detail package licensing

From: Ricardo Simoes <[email protected]>

This series corrects the licensing metadata:

- Patch 1 backports a patch which fixes the libgpiodbus license

- Patch 2 splits the recipe-wide LICENSE into per-package assignments, so each package reports its own license (e.g. the library as LGPL-2.1-or-later, the CLI tools as GPL-2.0-or-later).

Changes since v3:
- Fixed libgpiodbus backport patch commit message
- Fixed checksum of CC0-1.0 license file

Changes since v2:
- Inversed the order of the commits.

Changes since v1:
- Squashed addition of missing CC0-1.0 license into setting of per-package license assignements.
- Backported the license change of libgpiodbus from GPL-2.0-or-later to LGPL-2.1-or-later.

Ricardo Simoes (2):
libgpiod: update libgpiodbus license
libgpiod: set per-package license assignments

 .../libgpiod-2.x/fix_gpiodbus_license.patch   | 26 +++++++++++++++++++
 .../libgpiod/libgpiod_2.3.1.bb                | 15 ++++++++++-
 2 files changed, 40 insertions(+), 1 deletion(-)
 create mode 100644 meta-oe/recipes-support/libgpiod/libgpiod-2.x/fix_gpiodbus_license.patch

--
2.43.0

#1 lore raw

PATCH v4 1/2 libgpiod: update libgpiodbus license

From: Ricardo Simoes <[email protected]>

The license for libgpiodbus in upstream has been updated to LGPL-2.1-or-later.

Backport the patch from upstream so that libgpiodbus can use the LGPL-2.1-or-later license.

---
 .../libgpiod-2.x/fix_gpiodbus_license.patch   | 26 +++++++++++++++++++
 .../libgpiod/libgpiod_2.3.1.bb                |  1 +
 2 files changed, 27 insertions(+)
 create mode 100644 meta-oe/recipes-support/libgpiod/libgpiod-2.x/fix_gpiodbus_license.patch
meta-oe/recipes-support/libgpiod/libgpiod-2.x/fix_gpiodbus_license.patch new file +26 -0
new file mode 100644
index 0000000000..aa1eb0d8ab
@@ -0,0 +1,26 @@
+dbus: fix the license of gpiodbus.h
+
+The libgpiodbus library - which is entirely automatically generated with
+gdbus-codegen - was meant to be available under LGPLv2.1 like all the
+other shared libraries in this project. Change the SPDX tag in that
+file to LGPL-2.1-or-later.
+
+Fixes: a5ab76da1e0a ("dbus: add the D-Bus daemon, command-line client and tests")
+Link: https://patch.msgid.link/[email protected]
+Signed-off-by: Bartosz Golaszewski <[email protected]>
+
+Upstream-Status: Backport [https://git.kernel.org/pub/scm/libs/libgpiod/libgpiod.git/commit/?id=668a0efe918f9a763406239615175f759a6835f9]
+---
+ dbus/lib/gpiodbus.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/dbus/lib/gpiodbus.h b/dbus/lib/gpiodbus.h
+index 025c9c8586818051719078ba9d240f6d8b39e016..7557a576a5e9c6703ef78054ddc62a8b270de422 100644
+--- a/dbus/lib/gpiodbus.h
++++ b/dbus/lib/gpiodbus.h
+@@ -1,4 +1,4 @@
+-/* SPDX-License-Identifier: GPL-2.0-or-later */
++/* SPDX-License-Identifier: LGPL-2.1-or-later */
+ /* SPDX-FileCopyrightText: 2023 Bartosz Golaszewski <[email protected]> */
+
+ #ifndef __GPIODBUS_H__
meta-oe/recipes-support/libgpiod/libgpiod_2.3.1.bb +1 -0
index b3cb33ac89..fc8431c99c 100644
@@ -13,6 +13,7 @@ FILESEXTRAPATHS:prepend := "${THISDIR}/${BPN}-2.x:"
 
 SRC_URI += " \
     file://gpio-manager.init \
+    file://fix_gpiodbus_license.patch \
 "
 
 SRC_URI[sha256sum] = "e3a358a90a9204ff16f92b6f4028ed91460b1926f10589eb54b3566484650a30"

--
2.43.0

Reviewed-by on v4 1/2
#2 lore raw

Re: [meta-oe][PATCH v4 1/2] libgpiod: update libgpiodbus license

Quoted 11 lines · On Tue, 29 Sep 2026 15:13:45 +0200, <[email protected]> said:

From: Ricardo Simoes <[email protected]>

The license for libgpiodbus in upstream has been updated to LGPL-2.1-or-later.

Backport the patch from upstream so that libgpiodbus can use the LGPL-2.1-or-later license.

---

#3 lore raw

PATCH v4 2/2 libgpiod: set per-package license assignments

In reply to [email protected]

From: Ricardo Simoes <[email protected]>

libgpiod 2.x has more complex licensing than its 1.x counterpart, with multiple licenses applying to different parts of the project. Because the recipe has no per-package LICENSE statement, a user installing just the library (LGPL-2.1-or-later) might be led to believe it is also subject to GPL-2.0-or-later and the other aggregate licenses, which do not apply to that package.

Thus, to make it clear which licenses apply to which parts of the project, split the recipe-wide LICENSE into per-package values so that each generated package reports its actual license instead of the aggregate expression.

Additionally, the CC0-1.0 license has been added to the recipe to cover the 90-gpio.rules file

---
 meta-oe/recipes-support/libgpiod/libgpiod_2.3.1.bb | 14 +++++++++++++-
 1 file changed, 13 insertions(+), 1 deletion(-)
meta-oe/recipes-support/libgpiod/libgpiod_2.3.1.bb +13 -1
index fc8431c99c..49327591b7 100644
@@ -2,11 +2,23 @@ require libgpiod.inc
 
 inherit meson systemd update-rc.d useradd gobject-introspection
 
-LICENSE = "CC-BY-SA-4.0 AND GPL-2.0-or-later AND LGPL-2.1-or-later"
+LICENSE = "CC-BY-SA-4.0 AND CC0-1.0 AND GPL-2.0-or-later AND LGPL-2.1-or-later"
+LICENSE:${PN} = "LGPL-2.1-or-later"
+LICENSE:${PN}-cli = "GPL-2.0-or-later"
+LICENSE:${PN}-gpiosim = "LGPL-2.1-or-later"
+LICENSE:${PN}-glib = "LGPL-2.1-or-later"
+LICENSE:${PN}-manager = "GPL-2.0-or-later"
+LICENSE:${PN}-manager-cfg = "CC-BY-SA-4.0 AND CC0-1.0"
+LICENSE:${PN}-tools = "GPL-2.0-or-later"
+LICENSE:libgpiodbus = "LGPL-2.1-or-later"
+LICENSE:libgpiodcxx = "LGPL-2.1-or-later"
+LICENSE:libgpiotools = "LGPL-2.1-or-later"
+
 LIC_FILES_CHKSUM = " \
     file://LICENSES/GPL-2.0-or-later.txt;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
     file://LICENSES/LGPL-2.1-or-later.txt;md5=4b54a1fd55a448865a0b32d41598759d \
     file://LICENSES/CC-BY-SA-4.0.txt;md5=fba3b94d88bfb9b81369b869a1e9a20f \
+    file://LICENSES/CC0-1.0.txt;md5=65d3616852dbf7b1a6d4b53b00626032 \
 "
 
 FILESEXTRAPATHS:prepend := "${THISDIR}/${BPN}-2.x:"
Signature · 1 line
2.43.0
Reviewed-by on v4 2/2
#4 lore raw

Re: [meta-oe][PATCH v4 2/2] libgpiod: set per-package license assignments

Quoted 14 lines · On Tue, 29 Sep 2026 15:13:46 +0200, <[email protected]> said:

From: Ricardo Simoes <[email protected]>

libgpiod 2.x has more complex licensing than its 1.x counterpart, with multiple licenses applying to different parts of the project. Because the recipe has no per-package LICENSE statement, a user installing just the library (LGPL-2.1-or-later) might be led to believe it is also subject to GPL-2.0-or-later and the other aggregate licenses, which do not apply to that package.

Thus, to make it clear which licenses apply to which parts of the project, split the recipe-wide LICENSE into per-package values so that each generated package reports its actual license instead of the aggregate expression.

Quoted 6 lines

Additionally, the CC0-1.0 license has been added to the recipe to cover the 90-gpio.rules file

---

#5 lore raw
In reply to [email protected]
Quoted 27 lines · On Tue, 29 Sep 2026 15:13:44 +0200, <[email protected]> said:

From: Ricardo Simoes <[email protected]>

This series corrects the licensing metadata:

- Patch 1 backports a patch which fixes the libgpiodbus license

- Patch 2 splits the recipe-wide LICENSE into per-package assignments, so each package reports its own license (e.g. the library as LGPL-2.1-or-later, the CLI tools as GPL-2.0-or-later).

Changes since v3:
- Fixed libgpiodbus backport patch commit message
- Fixed checksum of CC0-1.0 license file

Changes since v2:
- Inversed the order of the commits.

Changes since v1:
- Squashed addition of missing CC0-1.0 license into setting of per-package license assignements.
- Backported the license change of libgpiodbus from GPL-2.0-or-later to LGPL-2.1-or-later.

Ricardo Simoes (2):
libgpiod: update libgpiodbus license
libgpiod: set per-package license assignments

Quoted 9 lines
 .../libgpiod-2.x/fix_gpiodbus_license.patch   | 26 +++++++++++++++++++
 .../libgpiod/libgpiod_2.3.1.bb                | 15 ++++++++++-
 2 files changed, 40 insertions(+), 1 deletion(-)
 create mode 100644 meta-oe/recipes-support/libgpiod/libgpiod-2.x/fix_gpiodbus_license.patch

--
2.43.0

You dropped my review tags.

Bart