yavta: import from meta-oe
[openembedded.git] / recipes / libnss-mdns / libnss-mdns_0.10.bb
blob584ca597ada1df165f8e123da79e3664c1c7c262
1 DESCRIPTION = "NSS module for Multicast DNS name resolution"
2 HOMEPAGE = "http://0pointer.de/lennart/projects/nss-mdns/"
3 LICENSE = "GPL"
4 SECTION = "libs"
5 PRIORITY = "optional"
7 RRECOMMENDS_${PN} = "zeroconf"
8 PR = "r0"
10 EXTRA_OECONF = "--libdir=/lib"
11 S = "${WORKDIR}/nss-mdns-${PV}"
13 SRC_URI = "http://0pointer.de/lennart/projects/nss-mdns/nss-mdns-${PV}.tar.gz"
15 inherit autotools
17 pkg_postinst_${PN} () {
18 # can't do this offline
19 if [ "x$D" != "x" ]; then
20 exit 1
22 cat /etc/nsswitch.conf | grep "hosts:\s*files dns$" > /dev/null && {
23 cat /etc/nsswitch.conf | sed 's/\(hosts:\s*files \)dns/\1mdns4_minimal [NOTFOUND=return] dns mdns4/' > /tmp/nsswitch.conf
24 mv /tmp/nsswitch.conf /etc/nsswitch.conf
28 pkg_prerm_${PN} () {
29 cat /etc/nsswitch.conf | grep "hosts:\s*files dns mdns$" > /dev/null && {
30 cat /etc/nsswitch.conf | sed 's/\(hosts:\s*files \)mdns4_minimal [NOTFOUND=return] dns mdns4/\1dns/' > /tmp/nsswitch.conf
31 mv /tmp/nsswitch.conf /etc/nsswitch.conf
35 SRC_URI[md5sum] = "03938f17646efbb50aa70ba5f99f51d7"
36 SRC_URI[sha256sum] = "1e683c2e7c3921814706d62fbbd3e9cbf493a75fa00255e0e715508d8134fa6d"