blob: a95062bc8b74565619f0ec925eb6a367732dee8b [file] [log] [blame]
Brad Bishopc342db32019-05-15 21:57:59 -04001# This package builds the NIS ypbind daemon
2# The source package is utils/net/NIS/ypbind-mt
3#
4require nis.inc
5
6DESCRIPTION = " \
7Multithreaded NIS bind service (ypbind-mt). \
8ypbind-mt is a complete new implementation of a NIS \
9binding daemon for Linux. It has the following \
10features. Supports ypbind protocol V1 and V2. \
11Uses threads for better response. Supports multiple \
12domain bindings. Supports /var/yp/binding/* file \
13for Linux libc 4/5 and glibc 2.x. Supports a list \
14of known secure NIS server (/etc/yp.conf) Binds to \
15the server which answered as first. \
16\
17This is the final IPv4-only version of ypbind-mt. \
18"
19HOMEPAGE = "https://github.com/thkukuk/ypbind-mt/"
20DEPENDS = " \
21 yp-tools \
22 ${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)} \
23 "
Patrick Williams213cb262021-08-07 19:21:33 -050024DEPENDS:append:libc-musl = " bsd-headers nss"
25RDEPENDS:${PN} += "yp-tools"
Brad Bishopc342db32019-05-15 21:57:59 -040026
27# ypbind-mt now provides all the functionality of ypbind
28# and is used in place of it.
29PROVIDES += "ypbind"
30
31SRC_URI = "https://github.com/thkukuk/ypbind-mt/releases/download/v${PV}/${BPN}-${PV}.tar.xz \
Andrew Geissler87f5cff2022-09-30 13:13:31 -050032 file://0001-dns_hosts-Fix-build-with-musl.patch \
Brad Bishopc342db32019-05-15 21:57:59 -040033 file://ypbind.init \
34 file://ypbind.service \
Brad Bishopc342db32019-05-15 21:57:59 -040035 "
Andrew Geissler87f5cff2022-09-30 13:13:31 -050036SRC_URI[sha256sum] = "064f2f185673c5493df83f6400b799f3a359de56118b6ba37c4327111f2fcd8b"
Brad Bishopc342db32019-05-15 21:57:59 -040037
38inherit systemd update-rc.d
39
Patrick Williams213cb262021-08-07 19:21:33 -050040SYSTEMD_SERVICE:${PN} = "ypbind.service"
Brad Bishopc342db32019-05-15 21:57:59 -040041INITSCRIPT_NAME = "ypbind"
42INITSCRIPT_PARAMS = "start 44 3 5 . stop 70 0 1 2 6 ."
43
44CACHED_CONFIGUREVARS = "ac_cv_prog_STRIP=/bin/true"
45
Patrick Williams213cb262021-08-07 19:21:33 -050046CFLAGS:append = " -I${STAGING_INCDIR}/nss3 -I${STAGING_INCDIR}/nspr"
Brad Bishopc342db32019-05-15 21:57:59 -040047
Patrick Williams213cb262021-08-07 19:21:33 -050048do_install:append () {
Brad Bishopc342db32019-05-15 21:57:59 -040049 install -d ${D}${sysconfdir}/init.d
50 install -d ${D}${sysconfdir}/rcS.d
51
52 install -m 0755 ${WORKDIR}/ypbind.init ${D}${sysconfdir}/init.d/ypbind
53
54 install -d ${D}${systemd_unitdir}/system
55 install -m 0644 ${WORKDIR}/ypbind.service ${D}${systemd_unitdir}/system
56}
57
Andrew Geissler87f5cff2022-09-30 13:13:31 -050058# uses glibc internal APIs e.g. _hostalias
59COMPATIBLE_HOST:libc-musl = "null"
Brad Bishopc342db32019-05-15 21:57:59 -040060
Patrick Williams213cb262021-08-07 19:21:33 -050061RPROVIDES:${PN} += "${PN}-systemd"
62RREPLACES:${PN} += "${PN}-systemd"
63RCONFLICTS:${PN} += "${PN}-systemd"