blob: dcdee6c46867ae4d97e0823ca478c7102d0040c3 [file] [log] [blame]
Brad Bishop6e60e8b2018-02-01 10:27:11 -05001SUMMARY = "Universal Addresses to RPC Program Number Mapper"
2DESCRIPTION = "The rpcbind utility is a server that converts RPC \
3 program numbers into universal addresses."
4SECTION = "console/network"
5HOMEPAGE = "http://sourceforge.net/projects/rpcbind/"
6BUGTRACKER = "http://sourceforge.net/tracker/?group_id=201237&atid=976751"
7DEPENDS = "libtirpc quota"
8
9LICENSE = "BSD"
10LIC_FILES_CHKSUM = "file://COPYING;md5=b46486e4c4a416602693a711bb5bfa39 \
11 file://src/rpcinfo.c;beginline=1;endline=27;md5=f8a8cd2cb25ac5aa16767364fb0e3c24"
12
13SRC_URI = "${SOURCEFORGE_MIRROR}/rpcbind/rpcbind-${PV}.tar.bz2 \
14 file://init.d \
Brad Bishop6e60e8b2018-02-01 10:27:11 -050015 file://rpcbind.conf \
16 file://rpcbind.socket \
17 file://rpcbind.service \
18 file://0001-rpcbind-pair-all-svc_getargs-calls-with-svc_freeargs.patch \
Brad Bishop316dfdd2018-06-25 12:45:53 -040019 file://pmapproc_dump-Fixed-typo-in-memory-leak-patch.patch \
20 file://rpcbproc_callit_com-Stop-freeing-a-static-pointer.patch \
Brad Bishop6e60e8b2018-02-01 10:27:11 -050021 "
Brad Bishop6e60e8b2018-02-01 10:27:11 -050022SRC_URI[md5sum] = "cf10cd41ed8228fc54c316191c1f07fe"
23SRC_URI[sha256sum] = "074a9a530dc7c11e0d905aa59bcb0847c009313f02e98d3d798aa9568f414c66"
24
25inherit autotools update-rc.d systemd pkgconfig
26
27PACKAGECONFIG ??= "tcp-wrappers"
28PACKAGECONFIG[tcp-wrappers] = "--enable-libwrap,--disable-libwrap,tcp-wrappers"
29
30INITSCRIPT_NAME = "rpcbind"
31INITSCRIPT_PARAMS = "start 12 2 3 4 5 . stop 60 0 1 6 ."
32
33SYSTEMD_SERVICE_${PN} = "rpcbind.service"
34
35inherit useradd
36
37USERADD_PACKAGES = "${PN}"
38USERADD_PARAM_${PN} = "--system --no-create-home --home-dir / \
39 --shell /bin/false --user-group rpc"
40
41PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}"
42PACKAGECONFIG[systemd] = "--with-systemdsystemunitdir=${systemd_unitdir}/system/, \
43 --without-systemdsystemunitdir, \
44 systemd \
45"
46
47EXTRA_OECONF += " --enable-warmstarts --with-rpcuser=rpc"
48
49do_install_append () {
50 mv ${D}${bindir} ${D}${sbindir}
51
52 install -d ${D}${sysconfdir}/init.d
53 sed -e 's,/etc/,${sysconfdir}/,g' \
54 -e 's,/sbin/,${sbindir}/,g' \
55 ${WORKDIR}/init.d > ${D}${sysconfdir}/init.d/rpcbind
56 chmod 0755 ${D}${sysconfdir}/init.d/rpcbind
57
58 install -m 0755 ${WORKDIR}/rpcbind.conf ${D}${sysconfdir}
59 install -d ${D}${systemd_unitdir}/system
60 install -m 0644 ${WORKDIR}/rpcbind.socket ${D}${systemd_unitdir}/system
61 install -m 0644 ${WORKDIR}/rpcbind.service ${D}${systemd_unitdir}/system
62 sed -i -e 's,@SBINDIR@,${sbindir},g' \
63 -e 's,@SYSCONFDIR@,${sysconfdir},g' \
64 ${D}${systemd_unitdir}/system/rpcbind.service
65}