Git-Url: 
http://git.frugalware.org/gitweb/gitweb.cgi?p=kdetesting2.git;a=commitdiff;h=99b246aafaae9e0fcbd1690ed98410efc89976e6

commit 99b246aafaae9e0fcbd1690ed98410efc89976e6
Author: Miklos Vajna <vmik...@frugalware.org>
Date:   Wed Jan 19 02:11:40 2011 +0100

rpcbind-0.2.0-1-i686

- new package, replaces portmap

diff --git a/source/network/rpcbind/FrugalBuild 
b/source/network/rpcbind/FrugalBuild
new file mode 100644
index 0000000..2454a1c
--- /dev/null
+++ b/source/network/rpcbind/FrugalBuild
@@ -0,0 +1,25 @@
+# Compiling Time: 0.13 SBU
+# Maintainer: Miklos Vajna <vmik...@frugalware.org>
+
+pkgname=rpcbind
+pkgver=0.2.0
+pkgrel=1
+pkgdesc="A server that converts RPC program numbers into universal addresses."
+_F_sourceforge_ext=".tar.bz2"
+Finclude sourceforge
+depends=('libtirpc' 'bash')
+replaces=('portmap')
+groups=('network')
+archs=('i686')
+source=($source rpcbind-sunrpc.patch rc.rpcbind)
+sha1sums=('02f077372a76a8f9adfa696004aa437212c28617' \
+          'a25c2295b2e4bf4e3f924f1753350efaccf37c21' \
+          'fc17ecef3b3237e98a3e19a5575fd72180954bb1')
+
+build()
+{
+       Fbuild
+       Frcd2 rpcbind
+}
+
+# optimization OK
diff --git a/source/network/rpcbind/rc.rpcbind 
b/source/network/rpcbind/rc.rpcbind
new file mode 100644
index 0000000..9bc35bd
--- /dev/null
+++ b/source/network/rpcbind/rc.rpcbind
@@ -0,0 +1,43 @@
+#!/bin/bash
+
+# (c) 2010 Miklos Vajna <vmik...@frugalware.org>
+# rc.rpcbind for Frugalware
+# distributed under GPL License
+
+# chkconfig: 345 13 87
+# description: RPC portmapper daemon
+
+source /lib/initscripts/functions
+TEXTDOMAIN=rpcbind
+TEXTDOMAINDIR=/lib/initscripts/messages
+
+actions=(restart start status stop)
+daemon=$"RPC portmapper"
+
+pid="cat /var/run/rpcbind.pid 2>/dev/null"
+
+rc_start()
+{
+       start_msg
+       if [ -z "$(eval $pid)" ]; then
+               /usr/bin/rpcbind
+               pidof rpcbind >/var/run/rpcbind.pid
+               ok $?
+       else
+               ok 999
+       fi
+}
+
+rc_stop()
+{
+       stop_msg
+       if [ -n "$(eval $pid)" ]; then
+               kill "$(eval $pid)"
+               rm -f /var/run/rpcbind.pid
+               ok $?
+       else
+               ok 999
+       fi
+}
+
+rc_exec $1
diff --git a/source/network/rpcbind/rpcbind-sunrpc.patch 
b/source/network/rpcbind/rpcbind-sunrpc.patch
new file mode 100644
index 0000000..76cf54b
--- /dev/null
+++ b/source/network/rpcbind/rpcbind-sunrpc.patch
@@ -0,0 +1,22 @@
+--- rpcbind-0.1.7/src/rpcbind.c.orig   2008-11-19 14:17:34.000000000 +0100
++++ rpcbind-0.1.7/src/rpcbind.c        2010-01-07 13:03:37.416632894 +0100
+@@ -114,7 +114,7 @@
+ char *udp_uaddr;      /* Universal UDP address */
+ char *tcp_uaddr;      /* Universal TCP address */
+ #endif
+-static char servname[] = "rpcbind";
++static char servname[] = "sunrpc";
+ static char superuser[] = "superuser";
+
+ int main __P((int, char *[]));
+--- rpcbind-0.1.7/src/rpcinfo.c~       2010-01-08 16:14:24.592156602 +0000
++++ rpcbind-0.1.7/src/rpcinfo.c        2010-01-08 16:14:31.578838609 +0000
+@@ -633,7 +633,7 @@
+       {
+         memset (&hints, 0, sizeof hints);
+         hints.ai_family = AF_INET;
+-        if ((error = getaddrinfo (host, "rpcbind", &hints, &res)) != 0 &&
++        if ((error = getaddrinfo (host, "sunrpc", &hints, &res)) != 0 &&
+               (error = getaddrinfo (host, "portmapper", &hints, &res)) != 0)
+           {
+             fprintf (stderr, "rpcinfo: %s: %s\n",
diff --git a/source/network/rpcbind/rpcbind.install 
b/source/network/rpcbind/rpcbind.install
new file mode 100644
index 0000000..f69c33a
--- /dev/null
+++ b/source/network/rpcbind/rpcbind.install
@@ -0,0 +1,13 @@
+post_install()
+{
+       chkconfig --add rc.rpcbind
+}
+
+post_remove()
+{
+       chkconfig --del rc.rpcbind
+}
+
+op=$1
+shift
+$op $*
_______________________________________________
Frugalware-git mailing list
Frugalware-git@frugalware.org
http://frugalware.org/mailman/listinfo/frugalware-git

Reply via email to