summaryrefslogtreecommitdiffstats
path: root/meta/recipes-connectivity/avahi/avahi_0.7.bb
diff options
context:
space:
mode:
authorChen Qi <Qi.Chen@windriver.com>2018-06-21 14:00:22 +0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2018-06-27 13:55:21 +0100
commit2b152d36581053b2fa9e81b2cd1664b885c951f0 (patch)
tree861368084dd1c9860c5fdcd58eb88b28a4878a14 /meta/recipes-connectivity/avahi/avahi_0.7.bb
parent19c22fc08a9ca778bcf79690cf7f27c3bf372211 (diff)
downloadpoky-2b152d36581053b2fa9e81b2cd1664b885c951f0.tar.gz
avahi: reorganize codes
This patch does nothing but reorganizing codes. avahi.inc is shared by avahi and avahi-ui recipes. Move common things into it, and move uncommon things out of it. (From OE-Core rev: 75529d384bfeaf52befccb892cf41f22dc02668b) Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-connectivity/avahi/avahi_0.7.bb')
-rw-r--r--meta/recipes-connectivity/avahi/avahi_0.7.bb83
1 files changed, 71 insertions, 12 deletions
diff --git a/meta/recipes-connectivity/avahi/avahi_0.7.bb b/meta/recipes-connectivity/avahi/avahi_0.7.bb
index 7c91f10f11..b695be9130 100644
--- a/meta/recipes-connectivity/avahi/avahi_0.7.bb
+++ b/meta/recipes-connectivity/avahi/avahi_0.7.bb
@@ -1,20 +1,79 @@
1require avahi.inc 1require avahi.inc
2 2
3inherit systemd 3SRC_URI += "file://00avahi-autoipd \
4 file://99avahi-autoipd \
5 file://initscript.patch \
6 "
7
8inherit update-rc.d systemd useradd
9
10PACKAGES =+ "libavahi-gobject avahi-daemon libavahi-common libavahi-core libavahi-client avahi-dnsconfd libavahi-glib avahi-autoipd avahi-utils"
11
12# As avahi doesn't put any files into PN, clear the files list to avoid problems
13# if extra libraries appear.
14FILES_${PN} = ""
15FILES_avahi-autoipd = "${sbindir}/avahi-autoipd \
16 ${sysconfdir}/avahi/avahi-autoipd.action \
17 ${sysconfdir}/dhcp/*/avahi-autoipd \
18 ${sysconfdir}/udhcpc.d/00avahi-autoipd \
19 ${sysconfdir}/udhcpc.d/99avahi-autoipd"
20FILES_libavahi-common = "${libdir}/libavahi-common.so.*"
21FILES_libavahi-core = "${libdir}/libavahi-core.so.* ${libdir}/girepository-1.0/AvahiCore*.typelib"
22FILES_avahi-daemon = "${sbindir}/avahi-daemon \
23 ${sysconfdir}/avahi/avahi-daemon.conf \
24 ${sysconfdir}/avahi/hosts \
25 ${sysconfdir}/avahi/services \
26 ${sysconfdir}/dbus-1 \
27 ${sysconfdir}/init.d/avahi-daemon \
28 ${datadir}/avahi/introspection/*.introspect \
29 ${datadir}/avahi/avahi-service.dtd \
30 ${datadir}/avahi/service-types \
31 ${datadir}/dbus-1/system-services"
32FILES_libavahi-client = "${libdir}/libavahi-client.so.*"
33FILES_avahi-dnsconfd = "${sbindir}/avahi-dnsconfd \
34 ${sysconfdir}/avahi/avahi-dnsconfd.action \
35 ${sysconfdir}/init.d/avahi-dnsconfd"
36FILES_libavahi-glib = "${libdir}/libavahi-glib.so.*"
37FILES_libavahi-gobject = "${libdir}/libavahi-gobject.so.* ${libdir}/girepository-1.0/Avahi*.typelib"
38FILES_avahi-utils = "${bindir}/avahi-*"
39
40RDEPENDS_${PN}-dev = "avahi-daemon (= ${EXTENDPKGV}) libavahi-core (= ${EXTENDPKGV}) libavahi-client (= ${EXTENDPKGV})"
41
42RRECOMMENDS_avahi-daemon_append_libc-glibc = " libnss-mdns"
43
44CONFFILES_avahi-daemon = "${sysconfdir}/avahi/avahi-daemon.conf"
45
46USERADD_PACKAGES = "avahi-daemon avahi-autoipd"
47USERADD_PARAM_avahi-daemon = "--system --home /run/avahi-daemon \
48 --no-create-home --shell /bin/false \
49 --user-group avahi"
50
51USERADD_PARAM_avahi-autoipd = "--system --home /run/avahi-autoipd \
52 --no-create-home --shell /bin/false \
53 --user-group \
54 -c \"Avahi autoip daemon\" \
55 avahi-autoipd"
56
57INITSCRIPT_PACKAGES = "avahi-daemon avahi-dnsconfd"
58INITSCRIPT_NAME_avahi-daemon = "avahi-daemon"
59INITSCRIPT_PARAMS_avahi-daemon = "defaults 21 19"
60INITSCRIPT_NAME_avahi-dnsconfd = "avahi-dnsconfd"
61INITSCRIPT_PARAMS_avahi-dnsconfd = "defaults 22 19"
4 62
5SYSTEMD_PACKAGES = "${PN}-daemon ${PN}-dnsconfd" 63SYSTEMD_PACKAGES = "${PN}-daemon ${PN}-dnsconfd"
6SYSTEMD_SERVICE_${PN}-daemon = "avahi-daemon.service" 64SYSTEMD_SERVICE_${PN}-daemon = "avahi-daemon.service"
7SYSTEMD_SERVICE_${PN}-dnsconfd = "avahi-dnsconfd.service" 65SYSTEMD_SERVICE_${PN}-dnsconfd = "avahi-dnsconfd.service"
8 66
9LIC_FILES_CHKSUM = "file://LICENSE;md5=2d5025d4aa3495befef8f17206a5b0a1 \ 67do_install_append() {
10 file://avahi-common/address.h;endline=25;md5=b1d1d2cda1c07eb848ea7d6215712d9d \ 68 install -d ${D}${sysconfdir}/udhcpc.d
11 file://avahi-core/dns.h;endline=23;md5=6fe82590b81aa0ddea5095b548e2fdcb \ 69 install ${WORKDIR}/00avahi-autoipd ${D}${sysconfdir}/udhcpc.d
12 file://avahi-daemon/main.c;endline=21;md5=9ee77368c5407af77caaef1b07285969 \ 70 install ${WORKDIR}/99avahi-autoipd ${D}${sysconfdir}/udhcpc.d
13 file://avahi-client/client.h;endline=23;md5=f4ac741a25c4f434039ba3e18c8674cf" 71}
14
15SRC_URI[md5sum] = "d76c59d0882ac6c256d70a2a585362a6"
16SRC_URI[sha256sum] = "57a99b5dfe7fdae794e3d1ee7a62973a368e91e414bd0dfa5d84434de5b14804"
17
18DEPENDS += "intltool-native"
19 72
20PACKAGES =+ "libavahi-gobject" 73# At the time the postinst runs, dbus might not be setup so only restart if running
74# Don't exit early, because update-rc.d needs to run subsequently.
75pkg_postinst_avahi-daemon () {
76if [ -z "$D" ]; then
77 killall -q -HUP dbus-daemon || true
78fi
79}