1 Summary: Universal addresses to RPC program number mapper
2 Summary(pl.UTF-8): Demon odwzorowujący adresy uniwersalne na numery programów RPC
8 Source0: http://downloads.sourceforge.net/rpcbind/%{name}-%{version}.tar.bz2
9 # Source0-md5: cf10cd41ed8228fc54c316191c1f07fe
11 Source2: %{name}.sysconfig
12 Source3: %{name}.service
13 Source4: %{name}.socket
14 Patch0: %{name}-libwrap.patch
15 Patch1: %{name}-syslog.patch
16 Patch2: %{name}-sunrpc.patch
17 Patch3: %{name}-nss.h.patch
18 Patch6: %{name}-tcp-addrs.patch
19 # http://nfsv4.bullopensource.org/doc/tirpc_rpcbind.php
20 URL: http://sourceforge.net/projects/rpcbind/
21 BuildRequires: autoconf >= 2.50
22 BuildRequires: automake
23 BuildRequires: libtirpc-devel >= 1:1.0.1
24 BuildRequires: libtool
25 BuildRequires: libwrap-devel
26 BuildRequires: pkgconfig
27 BuildRequires: rpmbuild(macros) >= 1.623
28 BuildRequires: systemd-devel
29 Requires(post,preun): /sbin/chkconfig
30 Requires(post,preun,postun): systemd-units >= 38
31 Requires: /sbin/chkconfig
32 Requires: rc-scripts >= 0.4.1.6
33 Requires: systemd-units >= 0.38
34 Provides: portmap = 8.0
37 Obsoletes: rpcbind-systemd
38 Conflicts: clusternfs < 3.0-0.rc2.3
39 Conflicts: flixengine < 8.0.8.2-1
40 Conflicts: nfs-utils < 1.1.0-0.rc2.1
41 Conflicts: quota-rquotad < 1:3.14-4
42 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
45 The rpcbind utility is a server that converts RPC program numbers into
46 universal addresses. It must be running on the host to be able to make
47 RPC calls on a server on that machine.
49 %description -l pl.UTF-8
50 Narzędzie rpcbind to serwer konwertujący numery programów RPC na
51 adresy uniwersalne. Musi działać na maszynie, aby można było wykonywać
52 wywołania RPC na serwerze na tej maszynie.
70 --with-statedir=/var/lib/rpcbind \
72 --with-systemdsystemunitdir=%{%systemdunitdir}
76 rm -rf $RPM_BUILD_ROOT
77 install -d $RPM_BUILD_ROOT{/sbin,%{_sbindir},/etc/{sysconfig,rc.d/init.d}} \
78 $RPM_BUILD_ROOT{%{_mandir}/man8,%{_var}/lib/%{name},%{systemdunitdir}}
80 install rpcbind $RPM_BUILD_ROOT/sbin
81 install rpcinfo $RPM_BUILD_ROOT%{_sbindir}
83 install man/{rpcbind,rpcinfo}.8 $RPM_BUILD_ROOT%{_mandir}/man8
85 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/rpcbind
86 install %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/rpcbind
88 install %{SOURCE3} $RPM_BUILD_ROOT%{systemdunitdir}/rpcbind.service
89 install %{SOURCE4} $RPM_BUILD_ROOT%{systemdunitdir}/rpcbind.socket
92 rm -rf $RPM_BUILD_ROOT
95 %useradd -u 22 -d /usr/share/empty -s /bin/false -c "Portmapper RPC User" -g nobody rpc
98 /sbin/chkconfig --add rpcbind
99 %service rpcbind restart
100 %systemd_post rpcbind.service
103 if [ "$1" = "0" ]; then
109 if [ "$1" = "0" ]; then
110 %service -q rpcbind stop
111 /sbin/chkconfig --del rpcbind
113 %systemd_preun rpcbind.service
115 %triggerpostun -- %{name} < 0.2.0-5
116 if [ -f /etc/sysconfig/rpcbind ]; then
117 . /etc/sysconfig/rpcbind
118 [ "$RPCBIND_VERBOSE" == "no" ] || RPCBIND_OPTIONS="-l"
119 [ "$RPCBIND_INSECURE" == "yes" ] && RPCBIND_OPTIONS="$RPCBIND_OPTIONS -i"
120 for a in $RPCBIND_ADDRESSES ; do
121 RPCBIND_OPTIONS="$RPCBIND_OPTIONS -h $a"
123 [ -z "$RPCBIND_OPTIONS" ] && exit 0
124 %{__cp} -f /etc/sysconfig/rpcbind /etc/sysconfig/rpcbind.rpmsave
125 echo >>/etc/sysconfig/rpcbind
126 echo "# Added by rpm trigger" >>/etc/sysconfig/rpcbind
127 echo "RPCBIND_OPTIONS=\"$RPCBIND_OPTIONS\"" >> /etc/sysconfig/rpcbind
129 %systemd_trigger rpcbind.service
132 %defattr(644,root,root,755)
133 %doc AUTHORS COPYING ChangeLog NEWS README
134 %attr(754,root,root) /etc/rc.d/init.d/rpcbind
135 %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/rpcbind
136 %attr(755,root,root) /sbin/rpcbind
137 %attr(755,root,root) %{_sbindir}/rpcinfo
138 %{_mandir}/man8/rpcbind.8*
139 %{_mandir}/man8/rpcinfo.8*
140 %dir %attr(700,rpc,root) %{_var}/lib/%{name}
141 %{systemdunitdir}/rpcbind.service
142 %{systemdunitdir}/rpcbind.socket