bluez5: change configuration directory mode
v4 cover bluez5: change configuration directory mode
From: Ming Liu <[email protected]>
The changes in V4:
1 In commit message, add reference to
https://git.kernel.org/pub/scm/bluetooth/bluez.git/commit/?id=00cfb36e20e3c35db2150e7d0351ad7b8442e2d8
2 Make testsdk directory writable before removing it.
Both as suggested by @Luca Ceresoli.
Ming Liu (2):
bluez5: change configuration directory mode
testsdk.py: ensure the testsdk directory is writable before removing
it
meta/lib/oeqa/sdk/testsdk.py | 4 ++++ meta/recipes-connectivity/bluez5/bluez5.inc | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-)
Signature · 1 line
2.25.1
PATCH v4 1/2 bluez5: change configuration directory mode
From: Ming Liu <[email protected]>
Change configuration directory mode from 0755 to 0555, this fixes a following warning when bluetoothd starts:
| ConfigurationDirectory 'bluetooth' already exists but the mode is different. | (File system: 755 ConfigurationDirectoryMode: 555)
--- meta/recipes-connectivity/bluez5/bluez5.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-connectivity/bluez5/bluez5.inc +1 -1
@@ -82,7 +82,7 @@ do_install:append() { install -d ${D}${INIT_D_DIR} install -m 0755 ${WORKDIR}/init ${D}${INIT_D_DIR}/bluetooth - install -d ${D}${sysconfdir}/bluetooth/ + install -m 0555 -d ${D}${sysconfdir}/bluetooth/ if [ -f ${S}/profiles/network/network.conf ]; then install -m 0644 ${S}/profiles/network/network.conf ${D}/${sysconfdir}/bluetooth/ fi
Signature · 1 line
2.25.1
Is this in a build with systemd or sysvinit? Looking at the referenced commit, that’s when running in a systemd-managed contained environment. In sysv that isn’t the case, so I’m not convinced this is the correct solution.
Ross
Quoted 42 lines · Ming Liu via lists.openembedded.org
From: Ming Liu <[email protected]>
Change configuration directory mode from 0755 to 0555, this fixes a following warning when bluetoothd starts:
| ConfigurationDirectory 'bluetooth' already exists but the mode is different. | (File system: 755 ConfigurationDirectoryMode: 555)Signed-off-by Ming Liu <[email protected]>---
meta/recipes-connectivity/bluez5/bluez5.inc | 2 +-1 file changed, 1 insertion(+), 1 deletion(-)meta/recipes-connectivity/bluez5/bluez5.inc +1
-1@@ -82,7 +82,7 @@ do_install:append() { install -d ${D}${INIT_D_DIR} install -m 0755 ${WORKDIR}/init ${D}${INIT_D_DIR}/bluetooth - install -d ${D}${sysconfdir}/bluetooth/ + install -m 0555 -d ${D}${sysconfdir}/bluetooth/ if [ -f ${S}/profiles/network/network.conf ]; then install -m 0644 ${S}/profiles/network/network.conf ${D}/${sysconfdir}/bluetooth/ fiSignature · 10 lines
2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#171494): https://lists.openembedded.org/g/openembedded-core/message/171494 Mute This Topic: https://lists.openembedded.org/mt/94155398/6875888 Group Owner: [email protected] Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [[email protected]] -=-=-=-=-=-=-=-=-=-=-=-
Hi, Ross:
I think it applies for both systemd and sysvinit, it's bluez5's requirement that /etc/bluetooth should be read-only.
//Ming Liu
Ross Burton <[email protected]> 於 2022年10月6日 週四 下午2:19寫道:
Quoted 57 lines
Is this in a build with systemd or sysvinit? Looking at the referenced commit, that’s when running in a systemd-managed contained environment. In sysv that isn’t the case, so I’m not convinced this is the correct solution.
Ross
Quoted 1 line
On 6 Oct 2022, at 12:27, Ming Liu via lists.openembedded.org
Quoted 6 lines · <[email protected]> wrote:
From: Ming Liu <[email protected]>
Change configuration directory mode from 0755 to 0555, this fixes a following warning when bluetoothd starts:
| ConfigurationDirectory 'bluetooth' already exists but the mode isdifferent.
Quoted 4 lines
| (File system: 755 ConfigurationDirectoryMode: 555)
Reference:
Review
Quoted 7 lines
Signed-off-by Ming Liu <[email protected]>---
meta/recipes-connectivity/bluez5/bluez5.inc | 2 +-1 file changed, 1 insertion(+), 1 deletion(-)(quoted diff) +0
-0b/meta/recipes-connectivity/bluez5/bluez5.inc
meta/recipes-connectivity/bluez5/bluez5.inc do_install:append() { · line 87
Quoted 11 lines
index
79d4645ca8..9f5c78b81e100644meta/recipes-connectivity/bluez5/bluez5.inc +1
-1@@ -82,7 +82,7 @@ do_install:append() { install -d ${D}${INIT_D_DIR} install -m 0755 ${WORKDIR}/init ${D}${INIT_D_DIR}/bluetooth - install -d ${D}${sysconfdir}/bluetooth/ + install -m 0555 -d ${D}${sysconfdir}/bluetooth/ if [ -f ${S}/profiles/network/network.conf ]; then install -m 0644 ${S}/profiles/network/network.conf${D}/${sysconfdir}/bluetooth/
Quoted 8 lines
meta/recipes-connectivity/bluez5/bluez5.inc +0
-1fi --2.25.1
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group. View/Reply Online (#171494):https://lists.openembedded.org/g/openembedded-core/message/171494
Quoted 3 lines
Mute This Topic: https://lists.openembedded.org/mt/94155398/6875888
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [Quoted 2 lines
-=-=-=-=-=-=-=-=-=-=-=-
PATCH v4 2/2 testsdk.py: ensure the testsdk directory is writable before removing it
In reply to [email protected]From: Ming Liu <[email protected]>
We have to make sure all users have write permission to testsdk directory before removing it, this is to avoid potential 'rm' failures.
--- meta/lib/oeqa/sdk/testsdk.py | 4 ++++ 1 file changed, 4 insertions(+)
meta/lib/oeqa/sdk/testsdk.py +4 -0
@@ -101,6 +101,10 @@ class TestSDK(TestSDKBase): processes = None sdk_dir = d.expand("${WORKDIR}/testimage-sdk/") + + # Ensure the Test SDK directory is writable for all users. + subprocess.check_output(['chmod', 'ugo+w', '-R', sdk_dir], stderr=subprocess.STDOUT) + bb.utils.remove(sdk_dir, True) bb.utils.mkdirhier(sdk_dir)
Signature · 1 line
2.25.1