Skip to contentSkip to conversation

package/avahi: Add sysusers.d snippet

PATCH New Chris Lesiak 3 participants 3 messages Jan 23, 2018 – Mar 26, 2018

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 package/avahi: Add sysusers.d snippet

---
 package/avahi/avahi.mk            | 9 +++++++++
 package/avahi/avahi_sysusers.conf | 5 +++++
 2 files changed, 14 insertions(+)
 create mode 100644 package/avahi/avahi_sysusers.conf
package/avahi/avahi.mk +9 -0
index ef621620f0..baffe3cb69 100644
@@ -190,6 +190,13 @@ endif
 
 ifeq ($(BR2_PACKAGE_AVAHI_DAEMON),y)
 
+ifeq ($(BR2_PACKAGE_SYSTEMD_SYSUSERS),y)
+define AVAHI_INSTALL_SYSTEMD_SYSUSERS
+	$(INSTALL) -D -m 644 package/avahi/avahi_sysusers.conf \
+		$(TARGET_DIR)/usr/lib/sysusers.d/avahi.conf
+endef
+endif
+
 define AVAHI_INSTALL_INIT_SYSTEMD
 	mkdir -p $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants
 
@@ -201,6 +208,8 @@ define AVAHI_INSTALL_INIT_SYSTEMD
 
 	$(INSTALL) -D -m 644 package/avahi/avahi_tmpfiles.conf \
 		$(TARGET_DIR)/usr/lib/tmpfiles.d/avahi.conf
+
+	$(AVAHI_INSTALL_SYSTEMD_SYSUSERS)
 endef
 
 define AVAHI_INSTALL_DAEMON_INIT_SYSV
package/avahi/avahi_sysusers.conf new file +5 -0
new file mode 100644
index 0000000000..463ce97cea
@@ -0,0 +1,5 @@
+# sysusers.d snippet for creating the avahi system user automatically
+# at boot on systemd-based systems that ship with an unpopulated
+# /etc. See sysusers.d(5) for details.
+
+u avahi - "Avahi mDNS/DNS-SD Stack"
Signature · 1 line
2.13.6
#1 lore raw

PATCH 1/1 package/avahi: Add sysusers.d snippet

Chris, all,

Quoted 48 lines · Chris Lesiak
---
 package/avahi/avahi.mk            | 9 +++++++++
 package/avahi/avahi_sysusers.conf | 5 +++++
 2 files changed, 14 insertions(+)
 create mode 100644 package/avahi/avahi_sysusers.conf
package/avahi/avahi.mk +9 -0
index ef621620f0..baffe3cb69 100644
@@ -190,6 +190,13 @@ endif
 
 ifeq ($(BR2_PACKAGE_AVAHI_DAEMON),y)
 
+ifeq ($(BR2_PACKAGE_SYSTEMD_SYSUSERS),y)
+define AVAHI_INSTALL_SYSTEMD_SYSUSERS
+       $(INSTALL) -D -m 644 package/avahi/avahi_sysusers.conf \
+               $(TARGET_DIR)/usr/lib/sysusers.d/avahi.conf
+endef
+endif
+
 define AVAHI_INSTALL_INIT_SYSTEMD
        mkdir -p $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants
 
@@ -201,6 +208,8 @@ define AVAHI_INSTALL_INIT_SYSTEMD
 
        $(INSTALL) -D -m 644 package/avahi/avahi_tmpfiles.conf \
                $(TARGET_DIR)/usr/lib/tmpfiles.d/avahi.conf
+
+       $(AVAHI_INSTALL_SYSTEMD_SYSUSERS)
 endef
 
 define AVAHI_INSTALL_DAEMON_INIT_SYSV
package/avahi/avahi_sysusers.conf new file +5 -1
new file mode 100644
index 0000000000..463ce97cea
@@ -0,0 +1,5 @@
+# sysusers.d snippet for creating the avahi system user automatically
+# at boot on systemd-based systems that ship with an unpopulated
+# /etc. See sysusers.d(5) for details.
+
+u avahi - "Avahi mDNS/DNS-SD Stack"
--

2.13.6

Quoted 4 lines

_______________________________________________
buildroot mailing list
buildroot at busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot

Regards,

Signature · 1 line
Samuel
#2 lore raw

PATCH 1/1 package/avahi: Add sysusers.d snippet

In reply to Chris Lesiak

Hello,

Quoted 1 line · Chris Lesiak

Applied to master, thanks. Do we need a similar thing for other packages ?

Best regards,

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin (formerly Free Electrons)
Embedded Linux and Kernel engineering
https://bootlin.com