| Message ID | 20250108110844.3849307-1-catalin.popescu@leica-geosystems.com |
|---|---|
| State | Rejected |
| Delegated to: | Steve Sakoman |
| Headers | show |
| Series | [scarthgap] bluez5: backport configuration file shipping from 5.73 to 5.72 | expand |
This is causing failures in autobuilder testing: https://errors.yoctoproject.org/Errors/Details/840027/ In particular: rm: cannot remove 'TOPDIR/tmp/work/qemux86_64-poky-linux/core-image-sato/1.0/testimage-sdk/sysroots/core2-64-poky-linux/etc/bluetooth/input.conf': Permission denied rm: cannot remove 'TOPDIR/tmp/work/qemux86_64-poky-linux/core-image-sato/1.0/testimage-sdk/sysroots/core2-64-poky-linux/etc/bluetooth/network.conf': Permission denied rm: cannot remove 'TOPDIR/tmp/work/qemux86_64-poky-linux/core-image-sato/1.0/testimage-sdk/sysroots/core2-64-poky-linux/etc/bluetooth/main.conf': Permission denied Steve On Wed, Jan 8, 2025 at 3:09 AM Catalin Popescu via lists.openembedded.org <catalin.popescu=leica-geosystems.com@lists.openembedded.org> wrote: > > Commit 49391fdcf71b32c5fd3c7b134c1d1c45cc1db388 removed the shipping of > configuration files from install task too early. The configuration files > shipping has been added to bluez5 5.73 whereas scarthgap is on older > version 5.72. To address this issue backport the patch from 5.73 to 5.72 > and add it to the bluez5 recipe. > > Signed-off-by: Catalin Popescu <catalin.popescu@leica-geosystems.com> > --- > meta/recipes-connectivity/bluez5/bluez5.inc | 1 + > ...l-config-files-with-enable-datafiles.patch | 61 +++++++++++++++++++ > 2 files changed, 62 insertions(+) > create mode 100644 meta/recipes-connectivity/bluez5/bluez5/0001-build-ship-all-config-files-with-enable-datafiles.patch > > diff --git a/meta/recipes-connectivity/bluez5/bluez5.inc b/meta/recipes-connectivity/bluez5/bluez5.inc > index 3f2f096aac..d7283fba00 100644 > --- a/meta/recipes-connectivity/bluez5/bluez5.inc > +++ b/meta/recipes-connectivity/bluez5/bluez5.inc > @@ -54,6 +54,7 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/bluetooth/bluez-${PV}.tar.xz \ > ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '', 'file://0001-Allow-using-obexd-without-systemd-in-the-user-sessio.patch', d)} \ > file://0001-tests-add-a-target-for-building-tests-without-runnin.patch \ > file://0001-test-gatt-Fix-hung-issue.patch \ > + file://0001-build-ship-all-config-files-with-enable-datafiles.patch \ > " > S = "${WORKDIR}/bluez-${PV}" > > diff --git a/meta/recipes-connectivity/bluez5/bluez5/0001-build-ship-all-config-files-with-enable-datafiles.patch b/meta/recipes-connectivity/bluez5/bluez5/0001-build-ship-all-config-files-with-enable-datafiles.patch > new file mode 100644 > index 0000000000..6e10674bf9 > --- /dev/null > +++ b/meta/recipes-connectivity/bluez5/bluez5/0001-build-ship-all-config-files-with-enable-datafiles.patch > @@ -0,0 +1,61 @@ > +From be0e796299b0e7a73bf06c5655b56180588550b0 Mon Sep 17 00:00:00 2001 > +From: Emil Velikov <emil.velikov@collabora.com> > +Date: Mon, 12 Feb 2024 20:02:44 +0000 > +Subject: [PATCH] build: ship all config files with --enable-datafiles > + > +Currently we ship only the dbus/systemd policy files and omit the other > +four - /etc/bluetooth/{main,mesh-main,input,network}.conf. > + > +Outside of those files, there is no documentation what the defaults are > +and the other possible options. A number of distributions (Arch, Gentoo, > +Fedora) have opted to manually copy those into the package. Alas this > +does not scale and leaves other distros at disadvantage, in a sense. > + > +Note: we need a custom install target to ensure confdir and statedir > +have the correct permissions. > + > +Upstream-Status: Backport [5.73] > +Signed-off-by: Emil Velikov <emil.velikov@collabora.com> > +--- > + Makefile.am | 8 +++++++- > + Makefile.mesh | 1 + > + 2 files changed, 8 insertions(+), 1 deletion(-) > + > +diff --git a/Makefile.am b/Makefile.am > +index 2b1b9acdf..2cbfed2db 100644 > +--- a/Makefile.am > ++++ b/Makefile.am > +@@ -31,11 +31,17 @@ AM_LDFLAGS = $(MISC_LDFLAGS) > + confdir = $(sysconfdir)/bluetooth > + statedir = $(localstatedir)/lib/bluetooth > + > ++install-data-hook: > ++ install -dm555 $(DESTDIR)$(confdir) > ++ install -dm700 $(DESTDIR)$(statedir) > ++ > + if DATAFILES > + dbusdir = $(DBUS_CONFDIR)/dbus-1/system.d > + dbus_DATA = src/bluetooth.conf > + > +-conf_DATA = > ++conf_DATA = src/main.conf > ++conf_DATA += profiles/input/input.conf > ++conf_DATA += profiles/network/network.conf > + state_DATA = > + endif > + > +diff --git a/Makefile.mesh b/Makefile.mesh > +index ea50383d2..e4c9fa6a3 100644 > +--- a/Makefile.mesh > ++++ b/Makefile.mesh > +@@ -3,6 +3,7 @@ if MESH > + > + if DATAFILES > + dbus_DATA += mesh/bluetooth-mesh.conf > ++conf_DATA += mesh/mesh-main.conf > + endif > + > + if SYSTEMD > +-- > +2.34.1 > + > > base-commit: 01423828248b75e1f5afe2e5959ccd971df875cd > -- > 2.34.1 > > > -=-=-=-=-=-=-=-=-=-=-=- > Links: You receive all messages sent to this group. > View/Reply Online (#209552): https://lists.openembedded.org/g/openembedded-core/message/209552 > Mute This Topic: https://lists.openembedded.org/mt/110494576/3620601 > Group Owner: openembedded-core+owner@lists.openembedded.org > Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [steve@sakoman.com] > -=-=-=-=-=-=-=-=-=-=-=- >
Hi Steve, The error doesn't look like to be related to my patch. BR, On 12/01/2025 15:23, Steve Sakoman wrote: > [You don't often get email from steve@sakoman.com. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ] > > This email is not from Hexagon’s Office 365 instance. Please be careful while clicking links, opening attachments, or replying to this email. > > > This is causing failures in autobuilder testing: > > https://errors.yoctoproject.org/Errors/Details/840027/ > > In particular: > > rm: cannot remove > 'TOPDIR/tmp/work/qemux86_64-poky-linux/core-image-sato/1.0/testimage-sdk/sysroots/core2-64-poky-linux/etc/bluetooth/input.conf': > Permission denied > rm: cannot remove > 'TOPDIR/tmp/work/qemux86_64-poky-linux/core-image-sato/1.0/testimage-sdk/sysroots/core2-64-poky-linux/etc/bluetooth/network.conf': > Permission denied > rm: cannot remove > 'TOPDIR/tmp/work/qemux86_64-poky-linux/core-image-sato/1.0/testimage-sdk/sysroots/core2-64-poky-linux/etc/bluetooth/main.conf': > Permission denied > > Steve > > On Wed, Jan 8, 2025 at 3:09 AM Catalin Popescu via > lists.openembedded.org > <catalin.popescu=leica-geosystems.com@lists.openembedded.org> wrote: >> Commit 49391fdcf71b32c5fd3c7b134c1d1c45cc1db388 removed the shipping of >> configuration files from install task too early. The configuration files >> shipping has been added to bluez5 5.73 whereas scarthgap is on older >> version 5.72. To address this issue backport the patch from 5.73 to 5.72 >> and add it to the bluez5 recipe. >> >> Signed-off-by: Catalin Popescu <catalin.popescu@leica-geosystems.com> >> --- >> meta/recipes-connectivity/bluez5/bluez5.inc | 1 + >> ...l-config-files-with-enable-datafiles.patch | 61 +++++++++++++++++++ >> 2 files changed, 62 insertions(+) >> create mode 100644 meta/recipes-connectivity/bluez5/bluez5/0001-build-ship-all-config-files-with-enable-datafiles.patch >> >> diff --git a/meta/recipes-connectivity/bluez5/bluez5.inc b/meta/recipes-connectivity/bluez5/bluez5.inc >> index 3f2f096aac..d7283fba00 100644 >> --- a/meta/recipes-connectivity/bluez5/bluez5.inc >> +++ b/meta/recipes-connectivity/bluez5/bluez5.inc >> @@ -54,6 +54,7 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/bluetooth/bluez-${PV}.tar.xz \ >> ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '', 'file://0001-Allow-using-obexd-without-systemd-in-the-user-sessio.patch', d)} \ >> file://0001-tests-add-a-target-for-building-tests-without-runnin.patch \ >> file://0001-test-gatt-Fix-hung-issue.patch \ >> + file://0001-build-ship-all-config-files-with-enable-datafiles.patch \ >> " >> S = "${WORKDIR}/bluez-${PV}" >> >> diff --git a/meta/recipes-connectivity/bluez5/bluez5/0001-build-ship-all-config-files-with-enable-datafiles.patch b/meta/recipes-connectivity/bluez5/bluez5/0001-build-ship-all-config-files-with-enable-datafiles.patch >> new file mode 100644 >> index 0000000000..6e10674bf9 >> --- /dev/null >> +++ b/meta/recipes-connectivity/bluez5/bluez5/0001-build-ship-all-config-files-with-enable-datafiles.patch >> @@ -0,0 +1,61 @@ >> +From be0e796299b0e7a73bf06c5655b56180588550b0 Mon Sep 17 00:00:00 2001 >> +From: Emil Velikov <emil.velikov@collabora.com> >> +Date: Mon, 12 Feb 2024 20:02:44 +0000 >> +Subject: [PATCH] build: ship all config files with --enable-datafiles >> + >> +Currently we ship only the dbus/systemd policy files and omit the other >> +four - /etc/bluetooth/{main,mesh-main,input,network}.conf. >> + >> +Outside of those files, there is no documentation what the defaults are >> +and the other possible options. A number of distributions (Arch, Gentoo, >> +Fedora) have opted to manually copy those into the package. Alas this >> +does not scale and leaves other distros at disadvantage, in a sense. >> + >> +Note: we need a custom install target to ensure confdir and statedir >> +have the correct permissions. >> + >> +Upstream-Status: Backport [5.73] >> +Signed-off-by: Emil Velikov <emil.velikov@collabora.com> >> +--- >> + Makefile.am | 8 +++++++- >> + Makefile.mesh | 1 + >> + 2 files changed, 8 insertions(+), 1 deletion(-) >> + >> +diff --git a/Makefile.am b/Makefile.am >> +index 2b1b9acdf..2cbfed2db 100644 >> +--- a/Makefile.am >> ++++ b/Makefile.am >> +@@ -31,11 +31,17 @@ AM_LDFLAGS = $(MISC_LDFLAGS) >> + confdir = $(sysconfdir)/bluetooth >> + statedir = $(localstatedir)/lib/bluetooth >> + >> ++install-data-hook: >> ++ install -dm555 $(DESTDIR)$(confdir) >> ++ install -dm700 $(DESTDIR)$(statedir) >> ++ >> + if DATAFILES >> + dbusdir = $(DBUS_CONFDIR)/dbus-1/system.d >> + dbus_DATA = src/bluetooth.conf >> + >> +-conf_DATA = >> ++conf_DATA = src/main.conf >> ++conf_DATA += profiles/input/input.conf >> ++conf_DATA += profiles/network/network.conf >> + state_DATA = >> + endif >> + >> +diff --git a/Makefile.mesh b/Makefile.mesh >> +index ea50383d2..e4c9fa6a3 100644 >> +--- a/Makefile.mesh >> ++++ b/Makefile.mesh >> +@@ -3,6 +3,7 @@ if MESH >> + >> + if DATAFILES >> + dbus_DATA += mesh/bluetooth-mesh.conf >> ++conf_DATA += mesh/mesh-main.conf >> + endif >> + >> + if SYSTEMD >> +-- >> +2.34.1 >> + >> >> base-commit: 01423828248b75e1f5afe2e5959ccd971df875cd >> -- >> 2.34.1 >> >> >> >>
On Mon, 13 Jan 2025 at 12:16, POPESCU Catalin via lists.openembedded.org <catalin.popescu=leica-geosystems.com@lists.openembedded.org> wrote: > The error doesn't look like to be related to my patch. > > rm: cannot remove > > 'TOPDIR/tmp/work/qemux86_64-poky-linux/core-image-sato/1.0/testimage-sdk/sysroots/core2-64-poky-linux/etc/bluetooth/input.conf': > > Permission denied > > rm: cannot remove > > 'TOPDIR/tmp/work/qemux86_64-poky-linux/core-image-sato/1.0/testimage-sdk/sysroots/core2-64-poky-linux/etc/bluetooth/network.conf': > > Permission denied > > rm: cannot remove > > 'TOPDIR/tmp/work/qemux86_64-poky-linux/core-image-sato/1.0/testimage-sdk/sysroots/core2-64-poky-linux/etc/bluetooth/main.conf': > > Permission denied Your patch is handling exactly these files, so it's better to see if you can reproduce the error. Alex
On 13/01/2025 12:23, Alexander Kanavin wrote: > [Some people who received this message don't often get email from alex.kanavin@gmail.com. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ] > > This email is not from Hexagon’s Office 365 instance. Please be careful while clicking links, opening attachments, or replying to this email. > > > On Mon, 13 Jan 2025 at 12:16, POPESCU Catalin via > lists.openembedded.org > <catalin.popescu=leica-geosystems.com@lists.openembedded.org> wrote: >> The error doesn't look like to be related to my patch. >>> rm: cannot remove >>> 'TOPDIR/tmp/work/qemux86_64-poky-linux/core-image-sato/1.0/testimage-sdk/sysroots/core2-64-poky-linux/etc/bluetooth/input.conf': >>> Permission denied >>> rm: cannot remove >>> 'TOPDIR/tmp/work/qemux86_64-poky-linux/core-image-sato/1.0/testimage-sdk/sysroots/core2-64-poky-linux/etc/bluetooth/network.conf': >>> Permission denied >>> rm: cannot remove >>> 'TOPDIR/tmp/work/qemux86_64-poky-linux/core-image-sato/1.0/testimage-sdk/sysroots/core2-64-poky-linux/etc/bluetooth/main.conf': >>> Permission denied > Your patch is handling exactly these files, so it's better to see if > you can reproduce the error. > > Alex I don't really know how to reproduce this error (which I don't see on my setup). It looks to be related to the permissions for the bluez config files so probably there are some other bluez patches that needs to be backported. One easier way to address the issue with the bluez config files not shipped on scarthgap would be to revert the actual commit that introduced the issue : commit 49391fdcf71b32c5fd3c7b134c1d1c45cc1db388 Author: Emil Kronborg <emil.kronborg@protonmail.com> Date: Thu Feb 22 19:44:59 2024 +0000 bluez5: remove configuration files from install task Since be0e796299b0 ("build: ship all config files with --enable-datafiles") in bluez, installing input.conf and network.conf has been redundant, as the bluez5 recipe already includes --enable-datafiles. Signed-off-by: Emil Kronborg <emil.kronborg@protonmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> This commit should have never been merged as long as scarthgap pulls in bluez 5.72 (The commit mentioned be0e796299b0 was merged in bluez 5.73 not in 5.72). If it's acceptable I can submit another patch. BR, Catalin
On Mon, 13 Jan 2025 at 14:07, POPESCU Catalin <catalin.popescu@leica-geosystems.com> wrote: > I don't really know how to reproduce this error (which I don't see on my > setup). Have you run the testsdk task specifically? Alex
On 13/01/2025 14:10, Alexander Kanavin wrote: > [Some people who received this message don't often get email from alex.kanavin@gmail.com. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ] > > This email is not from Hexagon’s Office 365 instance. Please be careful while clicking links, opening attachments, or replying to this email. > > > On Mon, 13 Jan 2025 at 14:07, POPESCU Catalin > <catalin.popescu@leica-geosystems.com> wrote: >> I don't really know how to reproduce this error (which I don't see on my >> setup). > Have you run the testsdk task specifically? > > Alex I don't have core-image-sato available on our build setup and there's no testsdk task available neither. So I can't reproduce the issue that easily. Reproducing the issue would require too much work and there's a better solution for the issue which is reverting the commit that introduced the issue on scarthgap.
On Mon, 13 Jan 2025 at 14:07, POPESCU Catalin <catalin.popescu@leica-geosystems.com> wrote: > One easier way to address the issue with the bluez config files not > shipped on scarthgap would be to revert the actual commit that > introduced the issue : > > commit 49391fdcf71b32c5fd3c7b134c1d1c45cc1db388 > Author: Emil Kronborg <emil.kronborg@protonmail.com> > Date: Thu Feb 22 19:44:59 2024 +0000 > > bluez5: remove configuration files from install task > > Since be0e796299b0 ("build: ship all config files with > --enable-datafiles") in bluez, installing input.conf and network.conf > has been redundant, as the bluez5 recipe already includes > --enable-datafiles. > > Signed-off-by: Emil Kronborg <emil.kronborg@protonmail.com> > Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> > > This commit should have never been merged as long as scarthgap pulls in > bluez 5.72 (The commit mentioned be0e796299b0 was merged in bluez 5.73 > not in 5.72). That is correct. I'd like to clarify from Emil how this change came to be, as oe-core master had only 5.72 at that point, and bluez recipe was updated to a later release much later. You can send a revert for scarthgap, please write a commit message that carefully explains the issue. Reverts in LTS make people nervous. Alex
diff --git a/meta/recipes-connectivity/bluez5/bluez5.inc b/meta/recipes-connectivity/bluez5/bluez5.inc index 3f2f096aac..d7283fba00 100644 --- a/meta/recipes-connectivity/bluez5/bluez5.inc +++ b/meta/recipes-connectivity/bluez5/bluez5.inc @@ -54,6 +54,7 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/bluetooth/bluez-${PV}.tar.xz \ ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '', 'file://0001-Allow-using-obexd-without-systemd-in-the-user-sessio.patch', d)} \ file://0001-tests-add-a-target-for-building-tests-without-runnin.patch \ file://0001-test-gatt-Fix-hung-issue.patch \ + file://0001-build-ship-all-config-files-with-enable-datafiles.patch \ " S = "${WORKDIR}/bluez-${PV}" diff --git a/meta/recipes-connectivity/bluez5/bluez5/0001-build-ship-all-config-files-with-enable-datafiles.patch b/meta/recipes-connectivity/bluez5/bluez5/0001-build-ship-all-config-files-with-enable-datafiles.patch new file mode 100644 index 0000000000..6e10674bf9 --- /dev/null +++ b/meta/recipes-connectivity/bluez5/bluez5/0001-build-ship-all-config-files-with-enable-datafiles.patch @@ -0,0 +1,61 @@ +From be0e796299b0e7a73bf06c5655b56180588550b0 Mon Sep 17 00:00:00 2001 +From: Emil Velikov <emil.velikov@collabora.com> +Date: Mon, 12 Feb 2024 20:02:44 +0000 +Subject: [PATCH] build: ship all config files with --enable-datafiles + +Currently we ship only the dbus/systemd policy files and omit the other +four - /etc/bluetooth/{main,mesh-main,input,network}.conf. + +Outside of those files, there is no documentation what the defaults are +and the other possible options. A number of distributions (Arch, Gentoo, +Fedora) have opted to manually copy those into the package. Alas this +does not scale and leaves other distros at disadvantage, in a sense. + +Note: we need a custom install target to ensure confdir and statedir +have the correct permissions. + +Upstream-Status: Backport [5.73] +Signed-off-by: Emil Velikov <emil.velikov@collabora.com> +--- + Makefile.am | 8 +++++++- + Makefile.mesh | 1 + + 2 files changed, 8 insertions(+), 1 deletion(-) + +diff --git a/Makefile.am b/Makefile.am +index 2b1b9acdf..2cbfed2db 100644 +--- a/Makefile.am ++++ b/Makefile.am +@@ -31,11 +31,17 @@ AM_LDFLAGS = $(MISC_LDFLAGS) + confdir = $(sysconfdir)/bluetooth + statedir = $(localstatedir)/lib/bluetooth + ++install-data-hook: ++ install -dm555 $(DESTDIR)$(confdir) ++ install -dm700 $(DESTDIR)$(statedir) ++ + if DATAFILES + dbusdir = $(DBUS_CONFDIR)/dbus-1/system.d + dbus_DATA = src/bluetooth.conf + +-conf_DATA = ++conf_DATA = src/main.conf ++conf_DATA += profiles/input/input.conf ++conf_DATA += profiles/network/network.conf + state_DATA = + endif + +diff --git a/Makefile.mesh b/Makefile.mesh +index ea50383d2..e4c9fa6a3 100644 +--- a/Makefile.mesh ++++ b/Makefile.mesh +@@ -3,6 +3,7 @@ if MESH + + if DATAFILES + dbus_DATA += mesh/bluetooth-mesh.conf ++conf_DATA += mesh/mesh-main.conf + endif + + if SYSTEMD +-- +2.34.1 +
Commit 49391fdcf71b32c5fd3c7b134c1d1c45cc1db388 removed the shipping of configuration files from install task too early. The configuration files shipping has been added to bluez5 5.73 whereas scarthgap is on older version 5.72. To address this issue backport the patch from 5.73 to 5.72 and add it to the bluez5 recipe. Signed-off-by: Catalin Popescu <catalin.popescu@leica-geosystems.com> --- meta/recipes-connectivity/bluez5/bluez5.inc | 1 + ...l-config-files-with-enable-datafiles.patch | 61 +++++++++++++++++++ 2 files changed, 62 insertions(+) create mode 100644 meta/recipes-connectivity/bluez5/bluez5/0001-build-ship-all-config-files-with-enable-datafiles.patch base-commit: 01423828248b75e1f5afe2e5959ccd971df875cd