Skip to contentSkip to conversation

fix for connmand start failure

Buildroot New Mike Williams 2 participants 3 messages Oct 13, 2015

lore
Share & tools
lore
#0 lore raw

I'm not sure if this is the best place way to fix the issue, but connmand no longer starts properly on current master due to a permissions error taking its name on the dbus system bus. Installing connman's connman-dbus.conf to /etc/dbus-1/system.d fixes the issue.

#1 lore raw

PATCH 1/1 connman: add missing dbus system bus configuration

---
 package/connman/connman.mk | 7 +++++++
 1 file changed, 7 insertions(+)
package/connman/connman.mk +7 -0
index 87d81ce..9d85493 100644
@@ -37,6 +37,11 @@ define CONNMAN_INSTALL_INIT_SYSTEMD
 		$(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/connman.service
 endef
 
+define CONNMAN_INSTALL_DBUS_CONF
+	$(INSTALL) -m 0644 -D $(@D)/src/connman-dbus.conf \
+		$(TARGET_DIR)/etc/dbus-1/system.d/
+endef
+
 ifeq ($(BR2_PACKAGE_CONNMAN_CLIENT),y)
 CONNMAN_CONF_OPTS += --enable-client
 CONNMAN_DEPENDENCIES += readline
@@ -50,4 +55,6 @@ else
 CONNMAN_CONF_OPTS += --disable-client
 endif
 
+CONNMAN_POST_INSTALL_TARGET_HOOKS += CONNMAN_INSTALL_DBUS_CONF
+
 $(eval $(autotools-package))
Signature · 1 line
2.1.4
#2 lore raw

PATCH 1/1 connman: add missing dbus system bus configuration

Dear Mike Williams,

Quoted 4 lines · Mike Williams
---
 package/connman/connman.mk | 7 +++++++
 1 file changed, 7 insertions(+)

Thanks for the patch. However, I believe it's not the proper way of solving the problem. Can you try the below patch instead:

package/connman/connman.mk +1 -0
index 87d81ce..3b14a80 100644
@@ -12,6 +12,7 @@ CONNMAN_INSTALL_STAGING = YES
 CONNMAN_LICENSE = GPLv2
 CONNMAN_LICENSE_FILES = COPYING
 CONNMAN_CONF_OPTS += \
+       --with-dbusconfdir=/etc \
        $(if $(BR2_PACKAGE_CONNMAN_DEBUG),--enable-debug,--disable-debug)               \
        $(if $(BR2_PACKAGE_CONNMAN_ETHERNET),--enable-ethernet,--disable-ethernet)      \
        $(if $(BR2_PACKAGE_CONNMAN_WIFI),--enable-wifi,--disable-wifi)                  \

This will make Connman automatically install its D-Bus configuration file in /etc/dbus-1/system.d/.

If it works for you, can you send a new version of the patch? For this new version, please include the explanation *inside* the commit log, and not in the cover letter.

Thanks a lot!

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com