1 # Copyright © 2018 Nick Bowler
2 # License GPLv3+: GNU General Public License version 3 or later.
3 # There is NO WARRANTY, to the extent permitted by law.
12 DESCRIPTION="NIS binding service (ypbind-mt)"
13 HOMEPAGE="https://www.thkukuk.de/nis/nis/ypbind-mt/"
14 SRC_URI="http://www.thkukuk.de/nis/download/$MY_PN/$MY_P.tar.bz2"
18 KEYWORDS="~amd64 ~x86"
19 IUSE="dbus nls slp systemd"
21 LIBDEPEND="slp? ( net-libs/openslp )
22 dbus? ( dev-libs/dbus-glib )
23 systemd? ( sys-apps/systemd:= )"
24 DEPEND="virtual/pkgconfig
26 nls? ( sys-devel/gettext )
28 RDEPEND="net-nds/yp-tools
32 PATCHES=("$FILESDIR/$P-fix-systemd-configuration.patch"
33 "$FILESDIR/$P-avoid-autopoint.patch"
34 "$FILESDIR/$P-flexible-bindingdir.patch")
45 local pidfile=${EPREFIX%/}/run/$PN.pid
46 local bindingdir=${EPREFIX%/}/var/yp/binding
47 local my_cppflags=("-D_YPBIND_PIDFILE=\\\"$pidfile\\\""
48 "-DBINDINGDIR=\\\"$bindingdir\\\"")
50 sed -f - "$FILESDIR/ypbind.initd" >ypbind.initd <<EOF || die
55 local myconf=($(use_enable nls) $(use_with systemd)
56 $(use_enable dbus dbus-nm) $(use_enable slp))
57 econf CPPFLAGS="${my_cppflags[*]}" "${myconf[@]}"
64 newinitd ypbind.initd ypbind